nmsg  0.9.0
Variables
http.c File Reference

base "http" message type. More...

Go to the source code of this file.

Variables

struct nmsg_msgmod_field http_fields []
 
struct nmsg_msgmod_plugin nmsg_msgmod_ctx
 

Detailed Description

base "http" message type.

This message type is meant to carry information about HTTP requests.

HTTP message fields.

Name Type Required Repeated

Description

type enum HttpType yes no

Type of HTTP connection.

srcip IP address no no

Client IP address

srchost string no no

Client hostname, if known

srcport uint16 no no

Client TCP port

dstip IP address no no

Server IP address

dstport uint16 no no

Server TCP port

request multi-line string no no

HTTP request and headers

enum HttpType values.

Name Value

Description

unknown 0

sinkhole 1

HTTP server is a sinkhole

Definition in file http.c.

Variable Documentation

struct nmsg_msgmod_field http_fields[]
Initial value:
= {
{
.name = "type",
},
{ .type = nmsg_msgmod_ft_ip, .name = "srcip" },
{ .type = nmsg_msgmod_ft_string, .name = "srchost" },
{ .type = nmsg_msgmod_ft_uint16, .name = "srcport" },
{ .type = nmsg_msgmod_ft_ip, .name = "dstip" },
{ .type = nmsg_msgmod_ft_uint16, .name = "dstport" },
{ .type = nmsg_msgmod_ft_mlstring, .name = "request" },
{ .type = nmsg_msgmod_ft_string, .name = "p0f_genre" },
{ .type = nmsg_msgmod_ft_string, .name = "p0f_detail" },
{ .type = nmsg_msgmod_ft_int16, .name = "p0f_dist" },
{ .type = nmsg_msgmod_ft_string, .name = "p0f_link" },
{ .type = nmsg_msgmod_ft_string, .name = "p0f_tos" },
{ .type = nmsg_msgmod_ft_uint16, .name = "p0f_fw" },
{ .type = nmsg_msgmod_ft_uint16, .name = "p0f_nat" },
{ .type = nmsg_msgmod_ft_uint16, .name = "p0f_real" },
{ .type = nmsg_msgmod_ft_int16, .name = "p0f_score" },
{ .type = nmsg_msgmod_ft_uint16, .name = "p0f_mflags" },
{ .type = nmsg_msgmod_ft_int32, .name = "p0f_uptime" },
NMSG_MSGMOD_FIELD_END
}
Protobuf enum.
Definition: msgmod.h:75
Protobuf int32.
Definition: msgmod.h:111
Protobuf byte array.
Definition: msgmod.h:96
Protobuf byte array.
Definition: msgmod.h:84
Protobuf int32.
Definition: msgmod.h:108
Protobuf byte array.
Definition: msgmod.h:90
Protobuf uint32.
Definition: msgmod.h:99
#define NMSG_MSGMOD_FIELD_REQUIRED
field is required
Definition: msgmod.h:124

Definition at line 25 of file http.c.

struct nmsg_msgmod_plugin nmsg_msgmod_ctx
Initial value:
= {
NMSG_MSGMOD_REQUIRED_INIT,
.vendor = NMSG_VENDOR_BASE,
.msgtype = { NMSG_VENDOR_BASE_HTTP_ID, NMSG_VENDOR_BASE_HTTP_NAME },
.pbdescr = &nmsg__base__http__descriptor,
.fields = http_fields
}

Definition at line 55 of file http.c.