kibana/docs/development/core/server/kibana-plugin-server.authenticationhandler.md
Mikhail Shustov 26bd65014b
Unify response interface in handler and request interceptors (#42442) (#42918)
* add response factory to the interceptors

* adopt x-pack code to the changes

* Add a separate response factory for lifecycles.

Only route handler can respond with 2xx response.
Interceptors may redirect or reject an incoming request.

* re-generate docs

* response.internal --> response.internalError

* use internalError for exceptions in authenticator

* before Security plugin proxied ES error status code. now sets explicitly.

* provide error via message field of error response for BWC

* update docs

* add customError response

* restore integration test and update unit tests

* update docs

* support Hapi error format for BWC

* add a couple of tests
2019-08-08 13:51:01 +02:00

514 B

Home > kibana-plugin-server > AuthenticationHandler

AuthenticationHandler type

Signature:

export declare type AuthenticationHandler = (request: KibanaRequest, response: LifecycleResponseFactory, toolkit: AuthToolkit) => AuthResult | KibanaResponse | Promise<AuthResult | KibanaResponse>;