Skip to content

Commit ab47855

Browse files
Doc: Use current Logstash SSL settings for auditbeat (#46457) (#46650)
(cherry picked from commit 49aa721) Co-authored-by: Karen Metts <[email protected]>
1 parent 3936f84 commit ab47855

File tree

1 file changed

+21
-21
lines changed

1 file changed

+21
-21
lines changed

docs/reference/auditbeat/configuring-ssl-logstash.md

Lines changed: 21 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -17,41 +17,41 @@ To use SSL mutual authentication:
1717
If you are using {{security-features}}, you can use the [elasticsearch-certutil tool](elasticsearch://reference/elasticsearch/command-line-tools/certutil.md) to generate certificates.
1818
::::
1919

20-
2. Configure Auditbeat to use SSL. In the `auditbeat.yml` config file, specify the following settings under `ssl`:
20+
2. Configure Auditbeat to use SSL. In the `auditbeat.yml` config file, specify these settings under `ssl`:
2121

22-
* `certificate_authorities`: Configures Auditbeat to trust any certificates signed by the specified CA. If `certificate_authorities` is empty or not set, the trusted certificate authorities of the host system are used.
23-
* `certificate` and `key`: Specifies the certificate and key that Auditbeat uses to authenticate with Logstash.
22+
* `certificate_authorities`. Configures Auditbeat to trust any certificates signed by the specified CA. If `certificate_authorities` is empty or not set, the trusted certificate authorities of the host system are used.
23+
* `certificate` and `key`. Specifies the certificate and key that Auditbeat uses to authenticate with Logstash.
2424

2525
For example:
2626

2727
```yaml
2828
output.logstash:
29-
hosts: ["logs.mycompany.com:5044"]
29+
hosts: ["logs.example.com:5044"]
3030
ssl.certificate_authorities: ["/etc/ca.crt"]
3131
ssl.certificate: "/etc/client.crt"
3232
ssl.key: "/etc/client.key"
3333
```
3434
3535
For more information about these configuration options, see [SSL](/reference/auditbeat/configuration-ssl.md).
3636
37-
3. Configure Logstash to use SSL. In the Logstash config file, specify the following settings for the [Beats input plugin for Logstash](logstash-docs-md://lsr/plugins-inputs-beats.md):
37+
3. Configure Logstash to use SSL. In the Logstash config file, specify these settings for the [Beats input plugin for Logstash](logstash-docs-md://lsr/plugins-inputs-beats.md):
3838
39-
* `ssl`: When set to true, enables Logstash to use SSL/TLS.
40-
* `ssl_certificate_authorities`: Configures Logstash to trust any certificates signed by the specified CA.
41-
* `ssl_certificate` and `ssl_key`: Specify the certificate and key that Logstash uses to authenticate with the client.
42-
* `ssl_verify_mode`: Specifies whether the Logstash server verifies the client certificate against the CA. You need to specify either `peer` or `force_peer` to make the server ask for the certificate and validate it. If you specify `force_peer`, and Auditbeat doesn’t provide a certificate, the Logstash connection will be closed. If you choose not to use [certutil](elasticsearch://reference/elasticsearch/command-line-tools/certutil.md), the certificates that you obtain must allow for both `clientAuth` and `serverAuth` if the extended key usage extension is present.
39+
* `ssl`. When set to true, enables Logstash to use SSL/TLS.
40+
* `ssl_certificate_authorities`. Configures Logstash to trust any certificates signed by the specified CA.
41+
* `ssl_certificate` and `ssl_key`. Specify the certificate and key that Logstash uses to authenticate with the client.
42+
* `ssl_client_authentication`. Specifies whether the Logstash server verifies the client certificate against the CA. You need to specify either `required` or `optional` to make the server ask for the certificate and validate it. If you specify `required`, and Auditbeat doesn’t provide a certificate, the Logstash connection will be closed. If you choose not to use [certutil](elasticsearch://reference/elasticsearch/command-line-tools/certutil.md), the certificates that you obtain must allow for both `clientAuth` and `serverAuth` if the extended key usage extension is present.
4343

4444
For example:
4545

4646
```json
4747
input {
4848
beats {
4949
port => 5044
50-
ssl => true
50+
ssl_enabled => true
5151
ssl_certificate_authorities => ["/etc/ca.crt"]
5252
ssl_certificate => "/etc/server.crt"
5353
ssl_key => "/etc/server.key"
54-
ssl_verify_mode => "force_peer"
54+
ssl_client_authentication => "required"
5555
}
5656
}
5757
```
@@ -65,35 +65,35 @@ To use SSL mutual authentication:
6565
Before running Auditbeat, you should validate the Logstash server’s certificate. You can use `curl` to validate the certificate even though the protocol used to communicate with Logstash is not based on HTTP. For example:
6666

6767
```shell
68-
curl -v --cacert ca.crt https://logs.mycompany.com:5044
68+
curl -v --cacert ca.crt https://logs.example.com:5044
6969
```
7070

7171
If the test is successful, you’ll receive an empty response error:
7272

7373
```shell
74-
* Rebuilt URL to: https://logs.mycompany.com:5044/
74+
* Rebuilt URL to: https://logs.example.com:5044/
7575
* Trying 192.168.99.100...
76-
* Connected to logs.mycompany.com (192.168.99.100) port 5044 (#0)
77-
* TLS 1.2 connection using TLS_DHE_RSA_WITH_AES_256_CBC_SHA
78-
* Server certificate: logs.mycompany.com
79-
* Server certificate: mycompany.com
76+
* Connected to logs.example.com (192.168.99.100) port 5044 (#0)
77+
* SSL connection using TLSv1.3 / TLS_AES_256_GCM_SHA384
78+
* Server certificate: logs.example.com
79+
* Server certificate: example.com
8080
> GET / HTTP/1.1
81-
> Host: logs.mycompany.com:5044
81+
> Host: logs.example.com:5044
8282
> User-Agent: curl/7.43.0
8383
> Accept: */*
8484
>
8585
* Empty reply from server
86-
* Connection #0 to host logs.mycompany.com left intact
86+
* Connection #0 to host logs.example.com left intact
8787
curl: (52) Empty reply from server
8888
```
8989

90-
The following example uses the IP address rather than the hostname to validate the certificate:
90+
This example uses the IP address rather than the hostname to validate the certificate:
9191

9292
```shell
9393
curl -v --cacert ca.crt https://192.168.99.100:5044
9494
```
9595

96-
Validation for this test fails because the certificate is not valid for the specified IP address. It’s only valid for the `logs.mycompany.com`, the hostname that appears in the Subject field of the certificate.
96+
Validation for this test fails because the certificate is not valid for the specified IP address. It’s only valid for the `logs.example.com`, the hostname that appears in the Subject field of the certificate.
9797

9898
```shell
9999
* Rebuilt URL to: https://192.168.99.100:5044/

0 commit comments

Comments
 (0)