logstash-codec-netflow 3.7.1 → 3.8.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
- SHA256:
3
- metadata.gz: 565c6ab7ab13d7903e04ee30abcc47d29af927f1689358f805036df90302ae87
4
- data.tar.gz: ea82070a59a0281f891a07d98a5bebdf71478284935c869ef3253266f8eea93b
2
+ SHA1:
3
+ metadata.gz: 0d51a96934f6215fa848ef5826f1da03ee4bf555
4
+ data.tar.gz: 01285e9dad3666666178a98dd50af9275fedb43b
5
5
  SHA512:
6
- metadata.gz: c9524679b1ca9860e3be04c68563a531328aa1119363d245927788bc905da15b683f2dfae48ef8e01d6559a66e19320841fddb72bf07f48616d600d320b08a46
7
- data.tar.gz: 9f6b5cff6f7662b392d7f38d672cb3fae272c2d2e28a656a2e7d7d2911f3f6f9a5a5a88aee4dd41a379605782673d1635ae7d0051a88c3f477e7a28b3027ed01
6
+ metadata.gz: a9e15da9958d4435051ba14da84768bd3db6b96ce0c8d7c80de3848ac2bfbcc5205f8d0cfd0415668447f3481fdedae3b5cea15bd9747124ac4aecbd648cc692
7
+ data.tar.gz: 1064815fd03ec5d7439f2fd3df9a9f50421742b8af83d002e62a3553005eb8cb1fa00ad1a43a8b19754fc2dd019bd963c35bb200a7b37ef6dbd8eea8a579c43f
data/CHANGELOG.md CHANGED
@@ -1,10 +1,12 @@
1
- ## 3.7.1
2
- - Update gemspec summary
1
+ ## 3.8.0
2
+
3
+ - Added initial YAF support with applabel and silk (but without DPI plugins because of complex data types)
3
4
 
4
5
  ## 3.7.1
5
6
 
7
+ - Update gemspec summary
6
8
  - Added support for CISCO1941/K9 software 15.1
7
-
9
+ - Added undocumented Netscaler fields
8
10
 
9
11
  ## 3.7.0
10
12
 
@@ -2100,6 +2100,301 @@
2100
2100
  541:
2101
2101
  - :uint32
2102
2102
  - :netscalerUnknown541
2103
+ 6871:
2104
+ 14:
2105
+ - :uint8
2106
+ - :initialTCPFlags
2107
+ 15:
2108
+ - :uint8
2109
+ - :unionTCPFlags
2110
+ 18:
2111
+ - :string
2112
+ - :payload
2113
+ 21:
2114
+ - :uint32
2115
+ - :reverseFlowDeltaMilliseconds
2116
+ 33:
2117
+ - :uint16
2118
+ - :silkAppLabel
2119
+ 35:
2120
+ - :uint8
2121
+ - :payloadEntropy
2122
+ 36:
2123
+ - :string
2124
+ - :osName
2125
+ 37:
2126
+ - :string
2127
+ - :osVersion
2128
+ 38:
2129
+ - :string
2130
+ - :firstPacketBanner
2131
+ 39:
2132
+ - :string
2133
+ - :secondPacketBanner
2134
+ 40:
2135
+ - :uint16
2136
+ - :flowAttributes
2137
+ 100:
2138
+ - :uint32
2139
+ - :expiredFragmentCount
2140
+ 101:
2141
+ - :uint32
2142
+ - :assembledFragmentCount
2143
+ 102:
2144
+ - :uint32
2145
+ - :meanFlowRate
2146
+ 103:
2147
+ - :uint32
2148
+ - :meanPacketRate
2149
+ 104:
2150
+ - :uint32
2151
+ - :flowTableFlushEventCount
2152
+ 105:
2153
+ - :uint32
2154
+ - :flowTablePeakCount
2155
+ 107:
2156
+ - :string
2157
+ - :osFingerPrint
2158
+ 126:
2159
+ - :string
2160
+ - :tftpFilename
2161
+ 127:
2162
+ - :string
2163
+ - :tftpMode
2164
+ 174:
2165
+ - :uint8
2166
+ - :dnsQueryResponse
2167
+ 175:
2168
+ - :uint16
2169
+ - :dnsQRType
2170
+ 176:
2171
+ - :uint8
2172
+ - :dnsAuthoritative
2173
+ 177:
2174
+ - :uint8
2175
+ - :dnsNXDomain
2176
+ 178:
2177
+ - :uint8
2178
+ - :dnsRRSection
2179
+ 179:
2180
+ - :string
2181
+ - :dnsQName
2182
+ 180:
2183
+ - :string
2184
+ - :dnsCName
2185
+ 181:
2186
+ - :uint16
2187
+ - :dnsMXPreference
2188
+ 182:
2189
+ - :string
2190
+ - :dnsMXExchange
2191
+ 183:
2192
+ - :string
2193
+ - :dnsNSDName
2194
+ 184:
2195
+ - :string
2196
+ - :dnsPTRDName
2197
+ 185:
2198
+ - :string
2199
+ - :sslCipher
2200
+ 186:
2201
+ - :uint8
2202
+ - :sslClientVersion
2203
+ 187:
2204
+ - :uint32
2205
+ - :sslServerCipher
2206
+ 188:
2207
+ - :uint8
2208
+ - :sslCompressionMethod
2209
+ 189:
2210
+ - :uint8
2211
+ - :sslCertVersion
2212
+ 190:
2213
+ - :string
2214
+ - :sslCertSignature
2215
+ 199:
2216
+ - :uint32
2217
+ - :dnsTTL
2218
+ 208:
2219
+ - :string
2220
+ - :dnsTXTData
2221
+ 209:
2222
+ - :uint32
2223
+ - :dnsSOASerial
2224
+ 210:
2225
+ - :uint32
2226
+ - :dnsSOARefresh
2227
+ 211:
2228
+ - :uint32
2229
+ - :dnsSOARetry
2230
+ 212:
2231
+ - :uint32
2232
+ - :dnsSOAExpire
2233
+ 213:
2234
+ - :uint32
2235
+ - :dnsSOAMinimum
2236
+ 214:
2237
+ - :string
2238
+ - :dnsSOAMName
2239
+ 215:
2240
+ - :string
2241
+ - :dnsSOARName
2242
+ 216:
2243
+ - :uint16
2244
+ - :dnsSRVPriority
2245
+ 217:
2246
+ - :uint16
2247
+ - :dnsSRVWeight
2248
+ 218:
2249
+ - :uint16
2250
+ - :dnsSRVPort
2251
+ 219:
2252
+ - :uint16
2253
+ - :dnsSRVTarget
2254
+ 223:
2255
+ - :uint32
2256
+ - :tcpUrgTotalCount
2257
+ 226:
2258
+ - :uint16
2259
+ - :dnsID
2260
+ 244:
2261
+ - :string
2262
+ - :sslCertSerialNumber
2263
+ 245:
2264
+ - :string
2265
+ - :sslObjectType
2266
+ 246:
2267
+ - :string
2268
+ - :sslObjectValue
2269
+ 247:
2270
+ - :string
2271
+ - :sslCertValidityNotBefore
2272
+ 248:
2273
+ - :string
2274
+ - :sslCertValidityNotAfter
2275
+ 249:
2276
+ - :string
2277
+ - :sslPublicKeyAlgorithm
2278
+ 250:
2279
+ - :string
2280
+ - :sslPublicKeyLength
2281
+ 287:
2282
+ - :uint8
2283
+ - :rtpPayloadType
2284
+ 288:
2285
+ - :uint8
2286
+ - :reverseRtpPayloadType
2287
+ 289:
2288
+ - :uint64
2289
+ - :mptcpInitialDataSequenceNumber
2290
+ 290:
2291
+ - :uint32
2292
+ - :mptcpReceiverToken
2293
+ 291:
2294
+ - :uint16
2295
+ - :mptcpMaximumSegmentSize
2296
+ 292:
2297
+ - :uint8
2298
+ - :mptcpAddressID
2299
+ 294:
2300
+ - :string
2301
+ - :sslServerName
2302
+ 295:
2303
+ - :string
2304
+ - :sslCertificateHash
2305
+ 293:
2306
+ - :uint8
2307
+ - :mptcpFlags
2308
+ 500:
2309
+ - :uint32
2310
+ - :smallPacketCount
2311
+ 501:
2312
+ - :uint32
2313
+ - :nonEmptyPacketCount
2314
+ 502:
2315
+ - :uint64
2316
+ - :dataByteCount
2317
+ 503:
2318
+ - :uint64
2319
+ - :averageInterarrivalTime
2320
+ 504:
2321
+ - :uint64
2322
+ - :standardDeviationInterarrivalTime
2323
+ 505:
2324
+ - :uint16
2325
+ - :firstNonEmptyPacketSize
2326
+ 506:
2327
+ - :uint16
2328
+ - :maxPacketSize
2329
+ 507:
2330
+ - :uint8
2331
+ - :firstEightNonEmptyPacketDirections
2332
+ 508:
2333
+ - :uint8
2334
+ - :standardDeviationPayloadLength
2335
+ 510:
2336
+ - :uint32
2337
+ - :largePacketCount
2338
+ 16398:
2339
+ - :uint8
2340
+ - :reverseInitialTCPFlags
2341
+ 16399:
2342
+ - :uint8
2343
+ - :reverseUnionTCPFlags
2344
+ 16402:
2345
+ - :string
2346
+ - :reversePayload
2347
+ 16419:
2348
+ - :uint8
2349
+ - :reversePayloadEntropy
2350
+ 16420:
2351
+ - :string
2352
+ - :reverseOsName
2353
+ 16421:
2354
+ - :string
2355
+ - :reverseOsVersion
2356
+ 16422:
2357
+ - :string
2358
+ - :reverseFirstPacketBanner
2359
+ 16423:
2360
+ - :string
2361
+ - :reverseSecondPacketBanner
2362
+ 16424:
2363
+ - :uint16
2364
+ - :reverseFlowAttributes
2365
+ 16491:
2366
+ - :string
2367
+ - :reverseOsFingerPrint
2368
+ 16671:
2369
+ - :uint8
2370
+ - :reverseRtpPayloadType
2371
+ 16884:
2372
+ - :uint32
2373
+ - :reverseSmallPacketCount
2374
+ 16885:
2375
+ - :uint32
2376
+ - :reverseNonEmptyPacketCount
2377
+ 16886:
2378
+ - :uint64
2379
+ - :reverseDataByteCount
2380
+ 16887:
2381
+ - :uint64
2382
+ - :reverseAverageInterarrivalTime
2383
+ 16888:
2384
+ - :uint64
2385
+ - :reverseStandardDeviationInterarrivalTime
2386
+ 16889:
2387
+ - :uint16
2388
+ - :reverseFirstNonEmptyPacketSize
2389
+ 16890:
2390
+ - :uint16
2391
+ - :reverseMaxPacketSize
2392
+ 16892:
2393
+ - :uint16
2394
+ - :reverseStandardDeviationPayloadLength
2395
+ 16894:
2396
+ - :uint32
2397
+ - :reverseLargePacketCount
2103
2398
  6876:
2104
2399
  880:
2105
2400
  - :uint8
@@ -1,7 +1,7 @@
1
1
  Gem::Specification.new do |s|
2
2
 
3
3
  s.name = 'logstash-codec-netflow'
4
- s.version = '3.7.1'
4
+ s.version = '3.8.0'
5
5
  s.licenses = ['Apache License (2.0)']
6
6
  s.summary = "Reads Netflow v5 and Netflow v9 data"
7
7
  s.description = "This gem is a Logstash plugin required to be installed on top of the Logstash core pipeline using $LS_HOME/bin/logstash-plugin install gemname. This gem is not a stand-alone program"
@@ -2014,8 +2014,126 @@ describe LogStash::Codecs::Netflow do
2014
2014
  end
2015
2015
  end
2016
2016
 
2017
+ context "IPFIX YAF basic with applabel" do
2018
+ # These samples have been generated with:
2019
+ # /usr/local/bin/yaf --silk --ipfix=udp --live=pcap --out=host02 --ipfix-port=2055 --in=eth0 --applabel --verbose --mac --verbose --max-payload 384
2020
+ let(:data) do
2021
+ packets = []
2022
+ packets << IO.read(File.join(File.dirname(__FILE__), "ipfix_test_yaf_tpls_option_tpl.dat"), :mode => "rb")
2023
+ packets << IO.read(File.join(File.dirname(__FILE__), "ipfix_test_yaf_tpl45841.dat"), :mode => "rb")
2024
+ packets << IO.read(File.join(File.dirname(__FILE__), "ipfix_test_yaf_data45841.dat"), :mode => "rb")
2025
+ packets << IO.read(File.join(File.dirname(__FILE__), "ipfix_test_yaf_data45873.dat"), :mode => "rb")
2026
+ packets << IO.read(File.join(File.dirname(__FILE__), "ipfix_test_yaf_data53248.dat"), :mode => "rb")
2027
+ end
2028
+
2029
+ let(:json_events) do
2030
+ events = []
2031
+ events << <<-END
2032
+ {
2033
+ "netflow": {
2034
+ "destinationIPv4Address": "172.16.32.100",
2035
+ "octetTotalCount": 132,
2036
+ "destinationTransportPort": 53,
2037
+ "vlanId": 0,
2038
+ "reversePacketTotalCount": 2,
2039
+ "reverseFlowDeltaMilliseconds": 1,
2040
+ "sourceIPv4Address": "172.16.32.201",
2041
+ "reverseVlanId": 0,
2042
+ "reverseIpClassOfService": 0,
2043
+ "reverseOctetTotalCount": 200,
2044
+ "reverseFlowAttributes": 0,
2045
+ "ipClassOfService": 0,
2046
+ "version": 10,
2047
+ "flowEndReason": 1,
2048
+ "protocolIdentifier": 17,
2049
+ "silkAppLabel": 53,
2050
+ "sourceTransportPort": 46086,
2051
+ "packetTotalCount": 2,
2052
+ "flowEndMilliseconds": "2016-12-25T12:58:35.819Z",
2053
+ "flowStartMilliseconds": "2016-12-25T12:58:35.818Z",
2054
+ "flowAttributes": 1
2055
+ },
2056
+ "@timestamp": "2016-12-25T13:03:38.000Z",
2057
+ "@version": "1"
2058
+ }
2059
+ END
2060
+
2061
+ events << <<-END
2062
+ {
2063
+ "netflow": {
2064
+ "destinationTransportPort": 9997,
2065
+ "reversePacketTotalCount": 2,
2066
+ "reverseFlowDeltaMilliseconds": 0,
2067
+ "sourceIPv4Address": "172.16.32.100",
2068
+ "reverseTcpSequenceNumber": 3788795034,
2069
+ "reverseVlanId": 0,
2070
+ "reverseOctetTotalCount": 92,
2071
+ "ipClassOfService": 2,
2072
+ "reverseInitialTCPFlags": 18,
2073
+ "tcpSequenceNumber": 340533701,
2074
+ "silkAppLabel": 0,
2075
+ "sourceTransportPort": 63499,
2076
+ "flowEndMilliseconds": "2016-12-25T12:58:34.346Z",
2077
+ "flowAttributes": 0,
2078
+ "destinationIPv4Address": "172.16.32.215",
2079
+ "octetTotalCount": 172,
2080
+ "vlanId": 0,
2081
+ "reverseIpClassOfService": 0,
2082
+ "reverseFlowAttributes": 0,
2083
+ "unionTCPFlags": 17,
2084
+ "version": 10,
2085
+ "flowEndReason": 3,
2086
+ "protocolIdentifier": 6,
2087
+ "initialTCPFlags": 194,
2088
+ "reverseUnionTCPFlags": 17,
2089
+ "packetTotalCount": 4,
2090
+ "flowStartMilliseconds": "2016-12-25T12:58:33.345Z"
2091
+ },
2092
+ "@timestamp": "2016-12-25T12:58:38.000Z",
2093
+ "@version": "1"
2094
+ }
2095
+ END
2096
+
2097
+ events << <<-END
2098
+ {
2099
+ "netflow": {
2100
+ "droppedPacketTotalCount": 0,
2101
+ "exporterIPv4Address": "172.16.32.201",
2102
+ "ignoredPacketTotalCount": 58,
2103
+ "meanPacketRate": 6,
2104
+ "flowTableFlushEventCount": 39,
2105
+ "flowTablePeakCount": 58,
2106
+ "version": 10,
2107
+ "exportedFlowRecordTotalCount": 31,
2108
+ "systemInitTimeMilliseconds": 1482670712000,
2109
+ "notSentPacketTotalCount": 0,
2110
+ "exportingProcessId": 0,
2111
+ "meanFlowRate": 0,
2112
+ "expiredFragmentCount": 0,
2113
+ "assembledFragmentCount": 0,
2114
+ "packetTotalCount": 1960
2115
+ },
2116
+ "@timestamp": "2016-12-25T13:03:33.000Z",
2117
+ "@version": "1"
2118
+ }
2119
+ END
2120
+ events.map{|event| event.gsub(/\s+/, "")}
2121
+ end
2122
+
2123
+ it "should decode raw data" do
2124
+ expect(decode.size).to eq(3)
2125
+ expect(decode[0].get("[netflow][silkAppLabel]")).to eq(53)
2126
+ expect(decode[1].get("[netflow][initialTCPFlags]")).to eq(194)
2127
+ expect(decode[2].get("[netflow][flowTablePeakCount]")).to eq(58)
2128
+ end
2017
2129
 
2130
+ it "should serialize to json" do
2131
+ expect(JSON.parse(decode[0].to_json)).to eq(JSON.parse(json_events[0]))
2132
+ expect(JSON.parse(decode[1].to_json)).to eq(JSON.parse(json_events[1]))
2133
+ expect(JSON.parse(decode[2].to_json)).to eq(JSON.parse(json_events[2]))
2134
+ end
2018
2135
 
2136
+ end
2019
2137
 
2020
2138
  end
2021
2139
 
metadata CHANGED
@@ -1,22 +1,22 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: logstash-codec-netflow
3
3
  version: !ruby/object:Gem::Version
4
- version: 3.7.1
4
+ version: 3.8.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Elastic
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2017-11-07 00:00:00.000000000 Z
11
+ date: 2017-11-11 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  requirement: !ruby/object:Gem::Requirement
15
15
  requirements:
16
- - - ">="
16
+ - - '>='
17
17
  - !ruby/object:Gem::Version
18
18
  version: '1.60'
19
- - - "<="
19
+ - - <=
20
20
  - !ruby/object:Gem::Version
21
21
  version: '2.99'
22
22
  name: logstash-core-plugin-api
@@ -24,16 +24,16 @@ dependencies:
24
24
  type: :runtime
25
25
  version_requirements: !ruby/object:Gem::Requirement
26
26
  requirements:
27
- - - ">="
27
+ - - '>='
28
28
  - !ruby/object:Gem::Version
29
29
  version: '1.60'
30
- - - "<="
30
+ - - <=
31
31
  - !ruby/object:Gem::Version
32
32
  version: '2.99'
33
33
  - !ruby/object:Gem::Dependency
34
34
  requirement: !ruby/object:Gem::Requirement
35
35
  requirements:
36
- - - ">="
36
+ - - '>='
37
37
  - !ruby/object:Gem::Version
38
38
  version: 1.5.0
39
39
  name: bindata
@@ -41,13 +41,13 @@ dependencies:
41
41
  type: :runtime
42
42
  version_requirements: !ruby/object:Gem::Requirement
43
43
  requirements:
44
- - - ">="
44
+ - - '>='
45
45
  - !ruby/object:Gem::Version
46
46
  version: 1.5.0
47
47
  - !ruby/object:Gem::Dependency
48
48
  requirement: !ruby/object:Gem::Requirement
49
49
  requirements:
50
- - - ">="
50
+ - - '>='
51
51
  - !ruby/object:Gem::Version
52
52
  version: 1.0.0
53
53
  name: logstash-devutils
@@ -55,12 +55,10 @@ dependencies:
55
55
  type: :development
56
56
  version_requirements: !ruby/object:Gem::Requirement
57
57
  requirements:
58
- - - ">="
58
+ - - '>='
59
59
  - !ruby/object:Gem::Version
60
60
  version: 1.0.0
61
- description: This gem is a Logstash plugin required to be installed on top of the
62
- Logstash core pipeline using $LS_HOME/bin/logstash-plugin install gemname. This
63
- gem is not a stand-alone program
61
+ description: This gem is a Logstash plugin required to be installed on top of the Logstash core pipeline using $LS_HOME/bin/logstash-plugin install gemname. This gem is not a stand-alone program
64
62
  email: info@elastic.co
65
63
  executables: []
66
64
  extensions: []
@@ -95,6 +93,11 @@ files:
95
93
  - spec/codecs/ipfix_test_vmware_vds_data266.dat
96
94
  - spec/codecs/ipfix_test_vmware_vds_data266_267.dat
97
95
  - spec/codecs/ipfix_test_vmware_vds_tpl.dat
96
+ - spec/codecs/ipfix_test_yaf_data45841.dat
97
+ - spec/codecs/ipfix_test_yaf_data45873.dat
98
+ - spec/codecs/ipfix_test_yaf_data53248.dat
99
+ - spec/codecs/ipfix_test_yaf_tpl45841.dat
100
+ - spec/codecs/ipfix_test_yaf_tpls_option_tpl.dat
98
101
  - spec/codecs/netflow5.dat
99
102
  - spec/codecs/netflow5_test_invalid01.dat
100
103
  - spec/codecs/netflow5_test_invalid02.dat
@@ -151,17 +154,17 @@ require_paths:
151
154
  - lib
152
155
  required_ruby_version: !ruby/object:Gem::Requirement
153
156
  requirements:
154
- - - ">="
157
+ - - '>='
155
158
  - !ruby/object:Gem::Version
156
159
  version: '0'
157
160
  required_rubygems_version: !ruby/object:Gem::Requirement
158
161
  requirements:
159
- - - ">="
162
+ - - '>='
160
163
  - !ruby/object:Gem::Version
161
164
  version: '0'
162
165
  requirements: []
163
166
  rubyforge_project:
164
- rubygems_version: 2.6.11
167
+ rubygems_version: 2.4.8
165
168
  signing_key:
166
169
  specification_version: 4
167
170
  summary: Reads Netflow v5 and Netflow v9 data
@@ -180,6 +183,11 @@ test_files:
180
183
  - spec/codecs/ipfix_test_vmware_vds_data266.dat
181
184
  - spec/codecs/ipfix_test_vmware_vds_data266_267.dat
182
185
  - spec/codecs/ipfix_test_vmware_vds_tpl.dat
186
+ - spec/codecs/ipfix_test_yaf_data45841.dat
187
+ - spec/codecs/ipfix_test_yaf_data45873.dat
188
+ - spec/codecs/ipfix_test_yaf_data53248.dat
189
+ - spec/codecs/ipfix_test_yaf_tpl45841.dat
190
+ - spec/codecs/ipfix_test_yaf_tpls_option_tpl.dat
183
191
  - spec/codecs/netflow5.dat
184
192
  - spec/codecs/netflow5_test_invalid01.dat
185
193
  - spec/codecs/netflow5_test_invalid02.dat