![]() |
MySQL 9.3.0
Source Code Documentation
|
#include <handler_authorize_login.h>
Public Types | |
using | Session = http::SessionManager::Session |
using | SessionPtr = http::SessionManager::SessionPtr |
using | Matcher = ::http::server::MatcherInterface |
![]() | |
using | HttpUri = ::http::base::Uri |
using | Protocol = ::mrs::endpoint::handler::Protocol |
![]() | |
enum class | Authorization { kNotNeeded , kRequires , kCheck } |
using | SqlSession = mysqlrouter::MySQLSession |
using | RequestContext = mrs::rest::RequestContext |
using | Parameters = mrs::interface::Parameters |
using | HttpResult = mrs::interface::HttpResult |
Public Member Functions | |
HandlerAuthorizeLogin (const Protocol protocol, const std::string &url_host, const UniversalId service_id, const std::string &service_path, const std::string &rest_path_matcher, const std::string &options, const std::string &redirection, const std::optional< std::string > &redirection_validator, interface::AuthorizeManager *auth_manager) | |
Authorization | requires_authentication () const override |
bool | may_check_access () const override |
UniversalId | get_service_id () const override |
UniversalId | get_db_object_id () const override |
UniversalId | get_schema_id () const override |
const std::string & | get_service_path () const override |
const std::string & | get_db_object_path () const override |
const std::string & | get_schema_path () const override |
uint32_t | get_access_rights () const override |
bool | request_begin (RequestContext *) override |
bool | request_error (RequestContext *ctxt, const http::Error &e) override |
HttpResult | handle_get (RequestContext *ctxt) override |
HttpResult | handle_post (RequestContext *ctxt, const std::vector< uint8_t > &document) override |
HttpResult | handle_delete (RequestContext *ctxt) override |
HttpResult | handle_put (RequestContext *ctxt) override |
![]() | |
void | request_end (RequestContext *ctxt) override |
![]() | |
Handler (const Protocol protocol, const std::string &url_host, const std::vector< std::string > &rest_path_matcher, const std::optional< std::string > &options, interface::AuthorizeManager *auth_manager) | |
~Handler () override | |
void | initialize (const Configuration &configuration) override |
const std::string & | get_url_host () const override |
const std::string & | get_protocol () const override |
bool | may_check_access () const override |
void | authorization (RequestContext *ctxt) override |
bool | request_begin (RequestContext *ctxt) override |
void | request_end (RequestContext *ctxt) override |
bool | request_error (RequestContext *ctxt, const http::Error &e) override |
Error handler. More... | |
const interface::Options & | get_options () const override |
void | throw_unauthorize_when_check_auth_fails (RequestContext *) |
uint32_t | check_privileges (const std::vector< database::entry::AuthPrivilege > &privileges, const UniversalId &service_id, const std::string &service_path, const UniversalId &schema_id, const std::string &schema_path, const UniversalId &db_object_id, const std::string &db_object_path) |
![]() | |
virtual | ~RestHandler ()=default |
virtual void | initialize (const Configuration &configuration)=0 |
Private Member Functions | |
std::string | append_status_parameters (const SessionPtr &session, const http::Error &error) const |
void | set_session_cookie (RequestContext *ctxt) const |
Private Attributes | |
UniversalId | service_id_ |
const std::string | service_path_ |
const std::string | redirection_ |
std::string | copy_url_ |
std::string | copy_path_ |
std::shared_ptr< Matcher > | redirection_validator_ |
Additional Inherited Members | |
![]() | |
const std::string & | empty_path () const |
![]() | |
interface::Options | options_ |
const std::string | url_host_ |
std::vector< std::string > | rest_path_matcher_ |
std::vector< void * > | handler_id_ |
interface::AuthorizeManager * | authorization_manager_ |
const std::string | protocol_ |
std::shared_ptr< Configuration > | configuration_ |
bool | log_level_is_debug_ |
bool | log_level_is_info_ |
mrs::endpoint::handler::HandlerAuthorizeLogin::HandlerAuthorizeLogin | ( | const Protocol | protocol, |
const std::string & | url_host, | ||
const UniversalId | service_id, | ||
const std::string & | service_path, | ||
const std::string & | rest_path_matcher, | ||
const std::string & | options, | ||
const std::string & | redirection, | ||
const std::optional< std::string > & | redirection_validator, | ||
interface::AuthorizeManager * | auth_manager | ||
) |
|
private |
|
overridevirtual |
Implements mrs::interface::RestHandler.
|
overridevirtual |
Implements mrs::interface::RestHandler.
|
overridevirtual |
Implements mrs::interface::RestHandler.
|
overridevirtual |
Implements mrs::interface::RestHandler.
|
overridevirtual |
Implements mrs::interface::RestHandler.
|
overridevirtual |
Implements mrs::interface::RestHandler.
|
overridevirtual |
Implements mrs::interface::RestHandler.
|
overridevirtual |
Implements mrs::interface::RestHandler.
|
overridevirtual |
Implements mrs::interface::RestHandler.
|
overridevirtual |
Implements mrs::interface::RestHandler.
|
overridevirtual |
Implements mrs::interface::RestHandler.
|
overridevirtual |
Implements mrs::interface::RestHandler.
|
overridevirtual |
Implements mrs::interface::RestHandler.
|
overridevirtual |
Reimplemented from mrs::endpoint::handler::HandlerAuthorizeBase.
|
overridevirtual |
Implements mrs::interface::RestHandler.
|
private |
|
private |
|
private |
|
private |
|
private |
|
private |
|
private |