Skip to content

Elasticsearch Output segfault with API Key Auth #10948

@graphaelli

Description

@graphaelli

Bug Report

To Reproduce

  • Configure API Key authentication for the elasticsearch output:
pipeline:
  outputs:
    - name: es
      match: '*'
      Suppress_Type_Name: On
      http_api_key: YmRZYWlaa0I1MzBTV3FWX1FicXc6QkROSDF5dVBjRWV2ekpadVY2VFFjQQ==
  • Start fluent-bit and immediately observe:
[engine] caught signal (SIGSEGV)
#0  0xaaaaaf6e1394      in  flb_sds_printf() at src/flb_sds.c:347
#1  0xaaaaafce936f      in  cb_es_flush() at plugins/out_es/es.c:893
#2  0xaaaaaf716a0b      in  output_pre_cb_flush() at include/fluent-bit/flb_output.h:701
#3  0xaaaab0a2e00b      in  co_switch() at lib/monkey/deps/flb_libco/aarch64.c:133
#4  0xffffffffffffffff  in  ???() at ???:0
Aborted (core dumped)

header_line = flb_sds_printf(NULL, "ApiKey %s", ctx->http_api_key);
is the culprit

Introduced with the addition of api key auth in #10461. This probably hasn't been reported previously because the option is not documented.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions