Skip to content

Conversation

@albertzaharovits
Copy link
Contributor

@albertzaharovits albertzaharovits commented Sep 30, 2019

The timeout.tcp_read AD/LDAP realm setting, despite the low-level allusion, controls the time interval the realms wait for a response for a query (search or bind). If the connection to the server is synchronous (un-pooled) the response timeout is analogous to the tcp read timeout. But the tcp read timeout is irrelevant in the common case of a pooled connection (when a Bind DN is specified).

The timeout.tcp_read qualifier is hereby deprecated in favor of timeout.response.

In addition, the default value for both timeout.tcp_read and timeout.response is that of timeout.ldap_search, instead of the 5s (but the default for timeout.ldap_search is still 5s). The timeout.ldap_search defines the server-controlled timeout of a search request. There is no practical use case to have a smaller tcp_read timeout compared to ldap_search (in this case the request would time-out on the client but continue to be processed on the server). The proposed change aims to simplify configuration so that the more common configuration change, adjusting timeout.ldap_search up, has the expected result (no timeout during searches) without any additional modifications.

Closes #46028

@albertzaharovits albertzaharovits added >deprecation :Security/Authentication Logging in, Usernames/passwords, Realms (Native/LDAP/AD/SAML/PKI/etc) v8.0.0 v7.5.0 labels Sep 30, 2019
@albertzaharovits albertzaharovits self-assigned this Sep 30, 2019
@elasticmachine
Copy link
Collaborator

Pinging @elastic/es-security

Copy link
Contributor

@jkakavas jkakavas left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@albertzaharovits
Copy link
Contributor Author

@elasticmachine update branch

@albertzaharovits
Copy link
Contributor Author

Note, I plan to follow-up with the deprecation check and the breaking change PRs when this is merged and backported.


[float]
[[ldap-ad-realms-tcp-read-timeout-removed]]
==== The `timeout.tcp_read` AD and LDAP realm settings have been removed
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm confused by the removed here. This PR doesn't remove them - I think this whole docs piece should be held over to the removal PR.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Agreed. I'll hold this off for the actual removal PR.

connection. This is equivalent to and is deprecated in favor of
`timeout.response` and they cannot be used simultaneously. An `s` at the end
indicates seconds, or `ms` indicates milliseconds. Defaults to the value of
`timeout.ldap_search`.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'd propose that we remove the "Defaults to ..." from here, since it is the deprecated setting, it doesn't really have a default.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Good point! If you one doesn't specify the deprecated settings, it's the new settings that takes a default value, the old one is just deprecated.

@albertzaharovits
Copy link
Contributor Author

@tvernum I have acted on your objections, please take another look.

@jimczi jimczi added v7.6.0 and removed v7.5.0 labels Nov 12, 2019
@polyfractal polyfractal added v7.7.0 and removed v7.6.0 labels Jan 15, 2020
@albertzaharovits
Copy link
Contributor Author

@elasticmachine update branch

elasticmachine and others added 2 commits January 28, 2020 07:43
…lastic#51492)

Changes the find_file_structure response to include a CSV
ingest processor in the ingest pipeline it suggests.

Previously the Kibana file upload functionality parsed CSV
in the browser, but by parsing CSV in the ingest pipeline
it makes the Kibana file upload functionality more easily
interchangable with Filebeat such that the configurations
it creates can more easily be used to import data with the
same structure repeatedly in production.
dnhatn and others added 4 commits January 28, 2020 16:54
We no longer issue new sync_ids in 8.0, but we still need to make sure 
that the replica allocator prefers copies with matching sync_id. This
commit adds tests for that.

Relates elastic#50776
Previous the formatter was breaking simple if/else statements (i.e.
without braces) onto separate lines, which could be fragile because the
formatter cannot also introduce braces. Instead, keep such expressions
on the same line.
@albertzaharovits albertzaharovits merged commit f016b17 into elastic:master Jan 28, 2020
@albertzaharovits
Copy link
Contributor Author

Aaaaargh, apologies for the bogus commit message!
The merge failed, and I compulsively clicked "Try again" although I knew it's wrong 😞

@albertzaharovits albertzaharovits deleted the unbound_id_response_timeout branch January 28, 2020 16:46
albertzaharovits added a commit that referenced this pull request Jan 29, 2020
The timeout.tcp_read AD/LDAP realm setting, despite the low-level
allusion, controls the time interval the realms wait for a response for
a query (search or bind). If the connection to the server is synchronous
(un-pooled) the response timeout is analogous to the tcp read timeout.
But the tcp read timeout is irrelevant in the common case of a pooled
connection (when a Bind DN is specified).

The timeout.tcp_read qualifier is hereby deprecated in favor of
timeout.response.

In addition, the default value for both timeout.tcp_read and
timeout.response is that of timeout.ldap_search, instead of the 5s (but
the default for timeout.ldap_search is still 5s). The
timeout.ldap_search defines the server-controlled timeout of a search
request. There is no practical use case to have a smaller tcp_read
timeout compared to ldap_search (in this case the request would time-out
on the client but continue to be processed on the server). The proposed
change aims to simplify configuration so that the more common
configuration change, adjusting timeout.ldap_search up, has the expected
result (no timeout during searches) without any additional
modifications.

Closes #46028
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

>deprecation :Security/Authentication Logging in, Usernames/passwords, Realms (Native/LDAP/AD/SAML/PKI/etc) v7.7.0 v8.0.0-alpha1

Projects

None yet

Development

Successfully merging this pull request may close these issues.

LDAP realm client side response timeout setting

10 participants