logstash-output-http 5.5.0 → 5.6.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/CHANGELOG.md +11 -0
- data/docs/index.asciidoc +115 -11
- data/lib/logstash/outputs/http.rb +7 -7
- data/logstash-output-http.gemspec +2 -2
- data/spec/outputs/http_spec.rb +3 -3
- metadata +5 -5
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 23e48e61a55be36ec256a7a4449f2aaf555f56253f3bb15d67e250e03cd39bf9
|
4
|
+
data.tar.gz: b61f7df593739a7ba2d892c62e29952c514d9274a5219c321bd6c96b09d33adb
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: a331795a25242f9f82c11746e6a3ecb619c18917dc91b77fb1f6ef8060a5ceb91d5effbfd171eeaac67ed8e7c12ad93ca3230ed279828ff8396dad71bd935882
|
7
|
+
data.tar.gz: 0fb511bb512aecf1caf602c44ed755c4be7c0c5a4781c651623dcaba5fc633f253611a7dd7bd25be2d1a66d52730ceb3e7e56ac031dfa8b093896f3e0bae63fc
|
data/CHANGELOG.md
CHANGED
@@ -1,3 +1,14 @@
|
|
1
|
+
## 5.6.1
|
2
|
+
- Added body logging for non 2xx responses [#142](https://github.com/logstash-plugins/logstash-output-http/pull/142)
|
3
|
+
|
4
|
+
## 5.6.0
|
5
|
+
- Added standardized SSL settings and deprecates their non-standard counterparts. Deprecated settings will continue to work, and will provide pipeline maintainers with guidance toward using their standardized counterparts [#140](https://github.com/logstash-plugins/logstash-output-http/pull/140)
|
6
|
+
- Added new `ssl_truststore_path`, `ssl_truststore_password`, and `ssl_truststore_type` settings for configuring SSL-trust using a PKCS-12 or JKS trust store, deprecating their `truststore`, `truststore_password`, and `truststore_type` counterparts.
|
7
|
+
- Added new `ssl_certificate_authorities` setting for configuring SSL-trust using a PEM-formatted list certificate authorities, deprecating its `cacert` counterpart.
|
8
|
+
- Added new `ssl_keystore_path`, `ssl_keystore_password`, and `ssl_keystore_type` settings for configuring SSL-identity using a PKCS-12 or JKS key store, deprecating their `keystore`, `keystore_password`, and `keystore_type` counterparts.
|
9
|
+
- Added new `ssl_certificate` and `ssl_key` settings for configuring SSL-identity using a PEM-formatted certificate/key pair, deprecating their `client_cert` and `client_key` counterparts.
|
10
|
+
- Added the `ssl_cipher_suites` option
|
11
|
+
|
1
12
|
## 5.5.0
|
2
13
|
- Feat: added `ssl_supported_protocols` option [#131](https://github.com/logstash-plugins/logstash-output-http/pull/131)
|
3
14
|
|
data/docs/index.asciidoc
CHANGED
@@ -74,9 +74,9 @@ This plugin supports the following configuration options plus the <<plugins-{typ
|
|
74
74
|
|=======================================================================
|
75
75
|
|Setting |Input type|Required
|
76
76
|
| <<plugins-{type}s-{plugin}-automatic_retries>> |<<number,number>>|No
|
77
|
-
| <<plugins-{type}s-{plugin}-cacert>> |a valid filesystem path|
|
78
|
-
| <<plugins-{type}s-{plugin}-client_cert>> |a valid filesystem path|
|
79
|
-
| <<plugins-{type}s-{plugin}-client_key>> |a valid filesystem path|
|
77
|
+
| <<plugins-{type}s-{plugin}-cacert>> |a valid filesystem path|__Deprecated__
|
78
|
+
| <<plugins-{type}s-{plugin}-client_cert>> |a valid filesystem path|__Deprecated__
|
79
|
+
| <<plugins-{type}s-{plugin}-client_key>> |a valid filesystem path|__Deprecated__
|
80
80
|
| <<plugins-{type}s-{plugin}-connect_timeout>> |<<number,number>>|No
|
81
81
|
| <<plugins-{type}s-{plugin}-content_type>> |<<string,string>>|No
|
82
82
|
| <<plugins-{type}s-{plugin}-cookies>> |<<boolean,boolean>>|No
|
@@ -87,9 +87,9 @@ This plugin supports the following configuration options plus the <<plugins-{typ
|
|
87
87
|
| <<plugins-{type}s-{plugin}-http_method>> |<<string,string>>, one of `["put", "post", "patch", "delete", "get", "head"]`|Yes
|
88
88
|
| <<plugins-{type}s-{plugin}-ignorable_codes>> |<<number,number>>|No
|
89
89
|
| <<plugins-{type}s-{plugin}-keepalive>> |<<boolean,boolean>>|No
|
90
|
-
| <<plugins-{type}s-{plugin}-keystore>> |a valid filesystem path|
|
91
|
-
| <<plugins-{type}s-{plugin}-keystore_password>> |<<password,password>>|
|
92
|
-
| <<plugins-{type}s-{plugin}-keystore_type>> |<<string,string>>|
|
90
|
+
| <<plugins-{type}s-{plugin}-keystore>> |a valid filesystem path|__Deprecated__
|
91
|
+
| <<plugins-{type}s-{plugin}-keystore_password>> |<<password,password>>|__Deprecated__
|
92
|
+
| <<plugins-{type}s-{plugin}-keystore_type>> |<<string,string>>|__Deprecated__
|
93
93
|
| <<plugins-{type}s-{plugin}-mapping>> |<<hash,hash>>|No
|
94
94
|
| <<plugins-{type}s-{plugin}-message>> |<<string,string>>|No
|
95
95
|
| <<plugins-{type}s-{plugin}-pool_max>> |<<number,number>>|No
|
@@ -100,11 +100,20 @@ This plugin supports the following configuration options plus the <<plugins-{typ
|
|
100
100
|
| <<plugins-{type}s-{plugin}-retry_non_idempotent>> |<<boolean,boolean>>|No
|
101
101
|
| <<plugins-{type}s-{plugin}-retryable_codes>> |<<number,number>>|No
|
102
102
|
| <<plugins-{type}s-{plugin}-socket_timeout>> |<<number,number>>|No
|
103
|
+
| <<plugins-{type}s-{plugin}-ssl_certificate>> |<<path,path>>|No
|
104
|
+
| <<plugins-{type}s-{plugin}-ssl_certificate_authorities>> |list of <<path,path>>|No
|
105
|
+
| <<plugins-{type}s-{plugin}-ssl_cipher_suites>> |list of <<string,string>>|No
|
106
|
+
| <<plugins-{type}s-{plugin}-ssl_keystore_password>> |<<password,password>>|No
|
107
|
+
| <<plugins-{type}s-{plugin}-ssl_keystore_path>> |<<path,path>>|No
|
108
|
+
| <<plugins-{type}s-{plugin}-ssl_keystore_type>> |<<string,string>>|No
|
103
109
|
| <<plugins-{type}s-{plugin}-ssl_supported_protocols>> |<<string,string>>|No
|
104
|
-
| <<plugins-{type}s-{plugin}-
|
105
|
-
| <<plugins-{type}s-{plugin}-
|
106
|
-
| <<plugins-{type}s-{plugin}-
|
107
|
-
| <<plugins-{type}s-{plugin}-
|
110
|
+
| <<plugins-{type}s-{plugin}-ssl_truststore_password>> |<<password,password>>|No
|
111
|
+
| <<plugins-{type}s-{plugin}-ssl_truststore_path>> |<<path,path>>|No
|
112
|
+
| <<plugins-{type}s-{plugin}-ssl_truststore_type>> |<<string,string>>|No
|
113
|
+
| <<plugins-{type}s-{plugin}-ssl_verification_mode>> |<<string,string>>, one of `["full", "none"]`|No
|
114
|
+
| <<plugins-{type}s-{plugin}-truststore>> |a valid filesystem path|__Deprecated__
|
115
|
+
| <<plugins-{type}s-{plugin}-truststore_password>> |<<password,password>>|__Deprecated__
|
116
|
+
| <<plugins-{type}s-{plugin}-truststore_type>> |<<string,string>>|__Deprecated__
|
108
117
|
| <<plugins-{type}s-{plugin}-url>> |<<string,string>>|Yes
|
109
118
|
| <<plugins-{type}s-{plugin}-validate_after_inactivity>> |<<number,number>>|No
|
110
119
|
|=======================================================================
|
@@ -127,6 +136,7 @@ See <<plugins-{type}s-{plugin}-retry_policy,Retry Policy>> for more information.
|
|
127
136
|
|
128
137
|
[id="plugins-{type}s-{plugin}-cacert"]
|
129
138
|
===== `cacert`
|
139
|
+
deprecated[5.6.0, Replaced by <<plugins-{type}s-{plugin}-ssl_certificate_authorities>>]
|
130
140
|
|
131
141
|
* Value type is <<path,path>>
|
132
142
|
* There is no default value for this setting.
|
@@ -135,6 +145,7 @@ If you need to use a custom X.509 CA (.pem certs) specify the path to that here
|
|
135
145
|
|
136
146
|
[id="plugins-{type}s-{plugin}-client_cert"]
|
137
147
|
===== `client_cert`
|
148
|
+
deprecated[5.6.0, Replaced by <<plugins-{type}s-{plugin}-ssl_certificate>>]
|
138
149
|
|
139
150
|
* Value type is <<path,path>>
|
140
151
|
* There is no default value for this setting.
|
@@ -143,6 +154,7 @@ If you'd like to use a client certificate (note, most people don't want this) se
|
|
143
154
|
|
144
155
|
[id="plugins-{type}s-{plugin}-client_key"]
|
145
156
|
===== `client_key`
|
157
|
+
deprecated[5.6.0, Replaced by <<plugins-{type}s-{plugin}-ssl_key>>]
|
146
158
|
|
147
159
|
* Value type is <<path,path>>
|
148
160
|
* There is no default value for this setting.
|
@@ -254,6 +266,7 @@ one with this to fix interactions with broken keepalive implementations.
|
|
254
266
|
|
255
267
|
[id="plugins-{type}s-{plugin}-keystore"]
|
256
268
|
===== `keystore`
|
269
|
+
deprecated[5.6.0, Replaced by <<plugins-{type}s-{plugin}-ssl_keystore_path>>]
|
257
270
|
|
258
271
|
* Value type is <<path,path>>
|
259
272
|
* There is no default value for this setting.
|
@@ -262,6 +275,7 @@ If you need to use a custom keystore (`.jks`) specify that here. This does not w
|
|
262
275
|
|
263
276
|
[id="plugins-{type}s-{plugin}-keystore_password"]
|
264
277
|
===== `keystore_password`
|
278
|
+
deprecated[5.6.0, Replaced by <<plugins-{type}s-{plugin}-ssl_keystore_password>>]
|
265
279
|
|
266
280
|
* Value type is <<password,password>>
|
267
281
|
* There is no default value for this setting.
|
@@ -270,7 +284,8 @@ Specify the keystore password here.
|
|
270
284
|
Note, most .jks files created with keytool require a password!
|
271
285
|
|
272
286
|
[id="plugins-{type}s-{plugin}-keystore_type"]
|
273
|
-
===== `keystore_type`
|
287
|
+
===== `keystore_type`
|
288
|
+
deprecated[5.6.0, Replaced by <<plugins-{type}s-{plugin}-ssl_keystore_type>>]
|
274
289
|
|
275
290
|
* Value type is <<string,string>>
|
276
291
|
* Default value is `"JKS"`
|
@@ -379,6 +394,67 @@ See <<plugins-{type}s-{plugin}-retry_policy,Retry Policy>> for more information.
|
|
379
394
|
|
380
395
|
Timeout (in seconds) to wait for data on the socket. Default is `10s`
|
381
396
|
|
397
|
+
[id="plugins-{type}s-{plugin}-ssl_certificate"]
|
398
|
+
===== `ssl_certificate`
|
399
|
+
* Value type is <<path,path>>
|
400
|
+
* There is no default value for this setting.
|
401
|
+
|
402
|
+
SSL certificate to use to authenticate the client. This certificate should be an OpenSSL-style X.509 certificate file.
|
403
|
+
|
404
|
+
NOTE: This setting can be used only if <<plugins-{type}s-{plugin}-ssl_key>> is set.
|
405
|
+
|
406
|
+
[id="plugins-{type}s-{plugin}-ssl_certificate_authorities"]
|
407
|
+
===== `ssl_certificate_authorities`
|
408
|
+
|
409
|
+
* Value type is a list of <<path,path>>
|
410
|
+
* There is no default value for this setting
|
411
|
+
|
412
|
+
The .cer or .pem CA files to validate the server's certificate.
|
413
|
+
|
414
|
+
[id="plugins-{type}s-{plugin}-ssl_cipher_suites"]
|
415
|
+
===== `ssl_cipher_suites`
|
416
|
+
|
417
|
+
* Value type is a list of <<string,string>>
|
418
|
+
* There is no default value for this setting
|
419
|
+
|
420
|
+
The list of cipher suites to use, listed by priorities.
|
421
|
+
Supported cipher suites vary depending on the Java and protocol versions.
|
422
|
+
|
423
|
+
[id="plugins-{type}s-{plugin}-ssl_key"]
|
424
|
+
===== `ssl_key`
|
425
|
+
|
426
|
+
* Value type is <<path,path>>
|
427
|
+
* There is no default value for this setting.
|
428
|
+
|
429
|
+
OpenSSL-style RSA private key that corresponds to the <<plugins-{type}s-{plugin}-ssl_certificate>>.
|
430
|
+
|
431
|
+
NOTE: This setting can be used only if <<plugins-{type}s-{plugin}-ssl_certificate>> is set.
|
432
|
+
|
433
|
+
[id="plugins-{type}s-{plugin}-ssl_keystore_password"]
|
434
|
+
===== `ssl_keystore_password`
|
435
|
+
|
436
|
+
* Value type is <<password,password>>
|
437
|
+
* There is no default value for this setting.
|
438
|
+
|
439
|
+
Set the keystore password
|
440
|
+
|
441
|
+
[id="plugins-{type}s-{plugin}-ssl_keystore_path"]
|
442
|
+
===== `ssl_keystore_path`
|
443
|
+
|
444
|
+
* Value type is <<path,path>>
|
445
|
+
* There is no default value for this setting.
|
446
|
+
|
447
|
+
The keystore used to present a certificate to the server.
|
448
|
+
It can be either `.jks` or `.p12`
|
449
|
+
|
450
|
+
[id="plugins-{type}s-{plugin}-ssl_keystore_type"]
|
451
|
+
===== `ssl_keystore_type`
|
452
|
+
|
453
|
+
* Value can be any of: `jks`, `pkcs12`
|
454
|
+
* If not provided, the value will be inferred from the keystore filename.
|
455
|
+
|
456
|
+
The format of the keystore file. It must be either `jks` or `pkcs12`.
|
457
|
+
|
382
458
|
[id="plugins-{type}s-{plugin}-ssl_supported_protocols"]
|
383
459
|
===== `ssl_supported_protocols`
|
384
460
|
|
@@ -396,6 +472,31 @@ NOTE: If you configure the plugin to use `'TLSv1.1'` on any recent JVM, such as
|
|
396
472
|
the protocol is disabled by default and needs to be enabled manually by changing `jdk.tls.disabledAlgorithms` in
|
397
473
|
the *$JDK_HOME/conf/security/java.security* configuration file. That is, `TLSv1.1` needs to be removed from the list.
|
398
474
|
|
475
|
+
[id="plugins-{type}s-{plugin}-ssl_truststore_password"]
|
476
|
+
===== `ssl_truststore_password`
|
477
|
+
|
478
|
+
* Value type is <<password,password>>
|
479
|
+
* There is no default value for this setting.
|
480
|
+
|
481
|
+
Set the truststore password
|
482
|
+
|
483
|
+
[id="plugins-{type}s-{plugin}-ssl_truststore_path"]
|
484
|
+
===== `ssl_truststore_path`
|
485
|
+
|
486
|
+
* Value type is <<path,path>>
|
487
|
+
* There is no default value for this setting.
|
488
|
+
|
489
|
+
The truststore to validate the server's certificate.
|
490
|
+
It can be either `.jks` or `.p12`.
|
491
|
+
|
492
|
+
[id="plugins-{type}s-{plugin}-ssl_truststore_type"]
|
493
|
+
===== `ssl_truststore_type`
|
494
|
+
|
495
|
+
* Value can be any of: `jks`, `pkcs12`
|
496
|
+
* If not provided, the value will be inferred from the truststore filename.
|
497
|
+
|
498
|
+
The format of the truststore file. It must be either `jks` or `pkcs12`.
|
499
|
+
|
399
500
|
[id="plugins-{type}s-{plugin}-ssl_verification_mode"]
|
400
501
|
===== `ssl_verification_mode`
|
401
502
|
|
@@ -414,6 +515,7 @@ Using `none` in production environments is strongly discouraged.
|
|
414
515
|
|
415
516
|
[id="plugins-{type}s-{plugin}-truststore"]
|
416
517
|
===== `truststore`
|
518
|
+
deprecated[5.6.0, Replaced by <<plugins-{type}s-{plugin}-ssl_truststore_path>>]
|
417
519
|
|
418
520
|
* Value type is <<path,path>>
|
419
521
|
* There is no default value for this setting.
|
@@ -422,6 +524,7 @@ If you need to use a custom truststore (`.jks`) specify that here. This does not
|
|
422
524
|
|
423
525
|
[id="plugins-{type}s-{plugin}-truststore_password"]
|
424
526
|
===== `truststore_password`
|
527
|
+
deprecated[5.6.0, Replaced by <<plugins-{type}s-{plugin}-ssl_truststore_password>>]
|
425
528
|
|
426
529
|
* Value type is <<password,password>>
|
427
530
|
* There is no default value for this setting.
|
@@ -431,6 +534,7 @@ Note, most .jks files created with keytool require a password!
|
|
431
534
|
|
432
535
|
[id="plugins-{type}s-{plugin}-truststore_type"]
|
433
536
|
===== `truststore_type`
|
537
|
+
deprecated[5.6.0, Replaced by <<plugins-{type}s-{plugin}-ssl_truststore_type>>]
|
434
538
|
|
435
539
|
* Value type is <<string,string>>
|
436
540
|
* Default value is `"JKS"`
|
@@ -7,7 +7,7 @@ require "logstash/plugin_mixins/http_client"
|
|
7
7
|
require "zlib"
|
8
8
|
|
9
9
|
class LogStash::Outputs::Http < LogStash::Outputs::Base
|
10
|
-
include LogStash::PluginMixins::HttpClient
|
10
|
+
include LogStash::PluginMixins::HttpClient[:with_deprecated => true]
|
11
11
|
|
12
12
|
concurrency :shared
|
13
13
|
|
@@ -154,12 +154,12 @@ class LogStash::Outputs::Http < LogStash::Outputs::Base
|
|
154
154
|
end
|
155
155
|
|
156
156
|
def log_error_response(response, url, event)
|
157
|
-
|
158
|
-
|
159
|
-
|
160
|
-
|
161
|
-
|
162
|
-
|
157
|
+
log_details = {
|
158
|
+
:code => response.code,
|
159
|
+
:body => response.body,
|
160
|
+
:url => url,
|
161
|
+
}
|
162
|
+
log_failure("Encountered non-2xx HTTP code", log_details)
|
163
163
|
end
|
164
164
|
|
165
165
|
def send_events(events)
|
@@ -1,6 +1,6 @@
|
|
1
1
|
Gem::Specification.new do |s|
|
2
2
|
s.name = 'logstash-output-http'
|
3
|
-
s.version = '5.
|
3
|
+
s.version = '5.6.1'
|
4
4
|
s.licenses = ['Apache License (2.0)']
|
5
5
|
s.summary = "Sends events to a generic HTTP or HTTPS endpoint"
|
6
6
|
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"
|
@@ -20,7 +20,7 @@ Gem::Specification.new do |s|
|
|
20
20
|
|
21
21
|
# Gem dependencies
|
22
22
|
s.add_runtime_dependency "logstash-core-plugin-api", ">= 1.60", "<= 2.99"
|
23
|
-
s.add_runtime_dependency "logstash-mixin-http_client", ">= 7.
|
23
|
+
s.add_runtime_dependency "logstash-mixin-http_client", ">= 7.3.0", "< 8.0.0"
|
24
24
|
|
25
25
|
s.add_development_dependency 'logstash-devutils'
|
26
26
|
s.add_development_dependency 'sinatra'
|
data/spec/outputs/http_spec.rb
CHANGED
@@ -417,10 +417,10 @@ end
|
|
417
417
|
|
418
418
|
RSpec.describe LogStash::Outputs::Http do # different block as we're starting web server with TLS
|
419
419
|
|
420
|
-
|
420
|
+
let(:default_server_settings) { TestApp.server_settings.dup }
|
421
421
|
|
422
422
|
before do
|
423
|
-
TestApp.server_settings =
|
423
|
+
TestApp.server_settings = default_server_settings.merge(webrick_config)
|
424
424
|
|
425
425
|
TestApp.last_request = nil
|
426
426
|
|
@@ -441,7 +441,7 @@ RSpec.describe LogStash::Outputs::Http do # different block as we're starting we
|
|
441
441
|
@server.shutdown # WEBrick::HTTPServer
|
442
442
|
|
443
443
|
TestApp.stop! rescue nil
|
444
|
-
TestApp.server_settings =
|
444
|
+
TestApp.server_settings = default_server_settings
|
445
445
|
end
|
446
446
|
|
447
447
|
let(:ssl_cert_host) { 'localhost' }
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: logstash-output-http
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 5.
|
4
|
+
version: 5.6.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Elastic
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2024-06-04 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
requirement: !ruby/object:Gem::Requirement
|
@@ -35,7 +35,7 @@ dependencies:
|
|
35
35
|
requirements:
|
36
36
|
- - ">="
|
37
37
|
- !ruby/object:Gem::Version
|
38
|
-
version: 7.
|
38
|
+
version: 7.3.0
|
39
39
|
- - "<"
|
40
40
|
- !ruby/object:Gem::Version
|
41
41
|
version: 8.0.0
|
@@ -46,7 +46,7 @@ dependencies:
|
|
46
46
|
requirements:
|
47
47
|
- - ">="
|
48
48
|
- !ruby/object:Gem::Version
|
49
|
-
version: 7.
|
49
|
+
version: 7.3.0
|
50
50
|
- - "<"
|
51
51
|
- !ruby/object:Gem::Version
|
52
52
|
version: 8.0.0
|
@@ -133,7 +133,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
133
133
|
- !ruby/object:Gem::Version
|
134
134
|
version: '0'
|
135
135
|
requirements: []
|
136
|
-
rubygems_version: 3.
|
136
|
+
rubygems_version: 3.2.33
|
137
137
|
signing_key:
|
138
138
|
specification_version: 4
|
139
139
|
summary: Sends events to a generic HTTP or HTTPS endpoint
|