]>
Commit | Line | Data |
---|---|---|
7c673cae | 1 | // -*- mode:C++; tab-width:8; c-basic-offset:2; indent-tabs-mode:t -*- |
9f95a23c | 2 | // vim: ts=8 sw=2 smarttab ft=cpp |
7c673cae | 3 | |
9f95a23c | 4 | #pragma once |
7c673cae FG |
5 | |
6 | #include "rgw_rest.h" | |
7 | #include "rgw_rest_s3.h" | |
8 | ||
9 | ||
10 | class RGWHandler_User : public RGWHandler_Auth_S3 { | |
11 | protected: | |
12 | RGWOp *op_get() override; | |
13 | RGWOp *op_put() override; | |
14 | RGWOp *op_post() override; | |
15 | RGWOp *op_delete() override; | |
16 | public: | |
17 | using RGWHandler_Auth_S3::RGWHandler_Auth_S3; | |
18 | ~RGWHandler_User() override = default; | |
19 | ||
f67539c2 | 20 | int read_permissions(RGWOp*, optional_yield) override { |
7c673cae FG |
21 | return 0; |
22 | } | |
23 | }; | |
24 | ||
25 | class RGWRESTMgr_User : public RGWRESTMgr { | |
26 | public: | |
27 | RGWRESTMgr_User() = default; | |
28 | ~RGWRESTMgr_User() override = default; | |
29 | ||
20effc67 | 30 | RGWHandler_REST *get_handler(rgw::sal::Store* store, |
f67539c2 | 31 | struct req_state*, |
7c673cae FG |
32 | const rgw::auth::StrategyRegistry& auth_registry, |
33 | const std::string&) override { | |
34 | return new RGWHandler_User(auth_registry); | |
35 | } | |
36 | }; |