Instances of ElasticSearch that are built to current best-practice standards, and wanting to make use of certain functionality, typically have Authentication enabled. The plugin does not connect to environments configured in this way.
Authentication may take the for of "Basic" authentication used with many web applications.
{
"statusCode": 401,
"body": {
"error": {
"root_cause": [
{
"type": "security_exception",
"reason": "missing authentication credentials for REST request [/index/_search?filter_path=hits.hits.fields]",
"header": {
"WWW-Authenticate": [
"Basic realm=\"security\" charset=\"UTF-8\"",
"Bearer realm=\"security\"",
"ApiKey"
]
}
}
],
"type": "security_exception",
"reason": "missing authentication credentials for REST request [/index/_search?filter_path=hits.hits.fields]",
"header": {
"WWW-Authenticate": [
"Basic realm=\"security\" charset=\"UTF-8\"",
"Bearer realm=\"security\"",
"ApiKey"
]
}
},
"status": 401
},
"headers": {
"www-authenticate": "Basic realm=\"security\" charset=\"UTF-8\", Bearer realm=\"security\", ApiKey",
"content-type": "application/json; charset=UTF-8",
"content-length": "561"
},
"request": {
"uri": {
"protocol": "https:",
"slashes": true,
"auth": null,
"host": "elastichost.domain.com:9200",
"port": "9200",
"hostname": "elastichost.domain.com",
"hash": null,
"search": "?filter_path=hits.hits.fields",
"query": "filter_path=hits.hits.fields",
"pathname": "/fs-departments/_search",
"path": "/index/_search?filter_path=hits.hits.fields",
"href": "https://elastichost.domain.com:9200/index/_search?filter_path=hits.hits.fields"
},
"method": "GET",
"headers": {
"Accept": "application/json",
"Content-Type": "application/json",
"User-Agent": "elasticdeveloper",
"content-length": 60
}
},
"message": "Unauthorized",
"completed": false,
"environment": {
"_textTokens": [
{
"_index": 0,
"_isValid": true,
"_depth": -1,
"_text": null,
"_offset": 0,
"_type": 0
},
{
"_index": 0,
"_isValid": true,
"_depth": 0,
"_text": "host",
"_offset": 8,
"_type": 5,
"_path": "host",
"_propertyValueToken": {
"_index": 0,
"_isValid": true,
"_depth": -1,
"_text": "https://elastichost.domain.com:9200",
"_offset": 16,
"_type": 6
}
},
{
"_index": 0,
"_isValid": true,
"_depth": 0,
"_text": "name",
"_offset": 64,
"_type": 5,
"_path": "name",
"_propertyValueToken": {
"_index": 0,
"_isValid": true,
"_depth": -1,
"_text": "esenv name",
"_offset": 72,
"_type": 6
}
},
{
"_index": 0,
"_isValid": true,
"_depth": 0,
"_text": "apikey",
"_offset": 95,
"_type": 5,
"_path": "apikey",
"_propertyValueToken": {
"_index": 0,
"_isValid": true,
"_depth": -1,
"_text": "SnVlNUlIa0IyTXFEX3l3WV9YWFM6dGVNNGN6dEdSY0s4d2NoRXJvNmw3Zw==",
"_offset": 105,
"_type": 6
}
}
],
"_version": null,
"_host": "https://elastichost.domain.com:9200",
"_name": "esenv name"
}
}
Would it be possible to add authentication support? Any assistance provided would be great.
Instances of ElasticSearch that are built to current best-practice standards, and wanting to make use of certain functionality, typically have Authentication enabled. The plugin does not connect to environments configured in this way.
Authentication may take the for of "Basic" authentication used with many web applications.
When connecting to such an environment the following error is generated:
{ "statusCode": 401, "body": { "error": { "root_cause": [ { "type": "security_exception", "reason": "missing authentication credentials for REST request [/index/_search?filter_path=hits.hits.fields]", "header": { "WWW-Authenticate": [ "Basic realm=\"security\" charset=\"UTF-8\"", "Bearer realm=\"security\"", "ApiKey" ] } } ], "type": "security_exception", "reason": "missing authentication credentials for REST request [/index/_search?filter_path=hits.hits.fields]", "header": { "WWW-Authenticate": [ "Basic realm=\"security\" charset=\"UTF-8\"", "Bearer realm=\"security\"", "ApiKey" ] } }, "status": 401 }, "headers": { "www-authenticate": "Basic realm=\"security\" charset=\"UTF-8\", Bearer realm=\"security\", ApiKey", "content-type": "application/json; charset=UTF-8", "content-length": "561" }, "request": { "uri": { "protocol": "https:", "slashes": true, "auth": null, "host": "elastichost.domain.com:9200", "port": "9200", "hostname": "elastichost.domain.com", "hash": null, "search": "?filter_path=hits.hits.fields", "query": "filter_path=hits.hits.fields", "pathname": "/fs-departments/_search", "path": "/index/_search?filter_path=hits.hits.fields", "href": "https://elastichost.domain.com:9200/index/_search?filter_path=hits.hits.fields" }, "method": "GET", "headers": { "Accept": "application/json", "Content-Type": "application/json", "User-Agent": "elasticdeveloper", "content-length": 60 } }, "message": "Unauthorized", "completed": false, "environment": { "_textTokens": [ { "_index": 0, "_isValid": true, "_depth": -1, "_text": null, "_offset": 0, "_type": 0 }, { "_index": 0, "_isValid": true, "_depth": 0, "_text": "host", "_offset": 8, "_type": 5, "_path": "host", "_propertyValueToken": { "_index": 0, "_isValid": true, "_depth": -1, "_text": "https://elastichost.domain.com:9200", "_offset": 16, "_type": 6 } }, { "_index": 0, "_isValid": true, "_depth": 0, "_text": "name", "_offset": 64, "_type": 5, "_path": "name", "_propertyValueToken": { "_index": 0, "_isValid": true, "_depth": -1, "_text": "esenv name", "_offset": 72, "_type": 6 } }, { "_index": 0, "_isValid": true, "_depth": 0, "_text": "apikey", "_offset": 95, "_type": 5, "_path": "apikey", "_propertyValueToken": { "_index": 0, "_isValid": true, "_depth": -1, "_text": "SnVlNUlIa0IyTXFEX3l3WV9YWFM6dGVNNGN6dEdSY0s4d2NoRXJvNmw3Zw==", "_offset": 105, "_type": 6 } } ], "_version": null, "_host": "https://elastichost.domain.com:9200", "_name": "esenv name" } }Would it be possible to add authentication support? Any assistance provided would be great.
Regards,
JohnB