From bb602506ac66e37dd4e82c69c127342bd57e1188 Mon Sep 17 00:00:00 2001 From: sdk-team Date: Mon, 11 Jul 2022 03:23:04 +0000 Subject: [PATCH] Add open file detect api. --- CHANGELOG | 3 + VERSION | 2 +- sas/CMakeLists.txt | 16 ++ sas/include/alibabacloud/sas/SasClient.h | 32 ++++ .../sas/model/CreateFileDetectRequest.h | 51 ++++++ .../sas/model/CreateFileDetectResult.h | 51 ++++++ .../model/CreateFileDetectUploadUrlRequest.h | 45 +++++ .../model/CreateFileDetectUploadUrlResult.h | 67 +++++++ .../sas/model/DescribeAlarmEventListRequest.h | 15 ++ .../sas/model/DescribeAssetSummaryResult.h | 2 + .../sas/model/DescribeSuspEventsRequest.h | 60 +++--- .../sas/model/DescribeVersionConfigResult.h | 4 + .../sas/model/DescribeVulDetailsResult.h | 1 + .../model/DescribeWarningExportInfoRequest.h | 45 +++++ .../model/DescribeWarningExportInfoResult.h | 65 +++++++ .../sas/model/GetFileDetectResultRequest.h | 48 +++++ .../sas/model/GetFileDetectResultResult.h | 61 +++++++ .../sas/model/ModifyOpenLogShipperRequest.h | 18 ++ sas/src/SasClient.cc | 144 +++++++++++++++ sas/src/model/CreateFileDetectRequest.cc | 63 +++++++ sas/src/model/CreateFileDetectResult.cc | 51 ++++++ .../model/CreateFileDetectUploadUrlRequest.cc | 44 +++++ .../model/CreateFileDetectUploadUrlResult.cc | 74 ++++++++ .../model/DescribeAlarmEventListRequest.cc | 45 +++++ sas/src/model/DescribeAssetSummaryResult.cc | 4 + sas/src/model/DescribeSuspEventsRequest.cc | 172 +++++++++++------- sas/src/model/DescribeVersionConfigResult.cc | 14 ++ sas/src/model/DescribeVulDetailsResult.cc | 2 + .../model/DescribeWarningExportInfoRequest.cc | 45 +++++ .../model/DescribeWarningExportInfoResult.cc | 100 ++++++++++ sas/src/model/GetFileDetectResultRequest.cc | 53 ++++++ sas/src/model/GetFileDetectResultResult.cc | 62 +++++++ sas/src/model/ModifyOpenLogShipperRequest.cc | 43 +++++ 33 files changed, 1409 insertions(+), 93 deletions(-) create mode 100644 sas/include/alibabacloud/sas/model/CreateFileDetectRequest.h create mode 100644 sas/include/alibabacloud/sas/model/CreateFileDetectResult.h create mode 100644 sas/include/alibabacloud/sas/model/CreateFileDetectUploadUrlRequest.h create mode 100644 sas/include/alibabacloud/sas/model/CreateFileDetectUploadUrlResult.h create mode 100644 sas/include/alibabacloud/sas/model/DescribeWarningExportInfoRequest.h create mode 100644 sas/include/alibabacloud/sas/model/DescribeWarningExportInfoResult.h create mode 100644 sas/include/alibabacloud/sas/model/GetFileDetectResultRequest.h create mode 100644 sas/include/alibabacloud/sas/model/GetFileDetectResultResult.h create mode 100644 sas/src/model/CreateFileDetectRequest.cc create mode 100644 sas/src/model/CreateFileDetectResult.cc create mode 100644 sas/src/model/CreateFileDetectUploadUrlRequest.cc create mode 100644 sas/src/model/CreateFileDetectUploadUrlResult.cc create mode 100644 sas/src/model/DescribeWarningExportInfoRequest.cc create mode 100644 sas/src/model/DescribeWarningExportInfoResult.cc create mode 100644 sas/src/model/GetFileDetectResultRequest.cc create mode 100644 sas/src/model/GetFileDetectResultResult.cc diff --git a/CHANGELOG b/CHANGELOG index 3ac203d44..190e7e0c0 100644 --- a/CHANGELOG +++ b/CHANGELOG @@ -1,3 +1,6 @@ +2022-07-11 Version: 1.36.1174 +- Add open file detect api. + 2022-07-08 Version: 1.36.1173 - Automatically generate sdk tasks. diff --git a/VERSION b/VERSION index bf4c7353c..99fb603dc 100644 --- a/VERSION +++ b/VERSION @@ -1 +1 @@ -1.36.1173 \ No newline at end of file +1.36.1174 \ No newline at end of file diff --git a/sas/CMakeLists.txt b/sas/CMakeLists.txt index 60172a25d..9c74420a0 100644 --- a/sas/CMakeLists.txt +++ b/sas/CMakeLists.txt @@ -31,6 +31,10 @@ set(sas_public_header_model include/alibabacloud/sas/model/CreateAntiBruteForceRuleResult.h include/alibabacloud/sas/model/CreateBackupPolicyRequest.h include/alibabacloud/sas/model/CreateBackupPolicyResult.h + include/alibabacloud/sas/model/CreateFileDetectRequest.h + include/alibabacloud/sas/model/CreateFileDetectResult.h + include/alibabacloud/sas/model/CreateFileDetectUploadUrlRequest.h + include/alibabacloud/sas/model/CreateFileDetectUploadUrlResult.h include/alibabacloud/sas/model/CreateOrUpdateAssetGroupRequest.h include/alibabacloud/sas/model/CreateOrUpdateAssetGroupResult.h include/alibabacloud/sas/model/CreateServiceLinkedRoleRequest.h @@ -285,6 +289,8 @@ set(sas_public_header_model include/alibabacloud/sas/model/DescribeVulListResult.h include/alibabacloud/sas/model/DescribeVulWhitelistRequest.h include/alibabacloud/sas/model/DescribeVulWhitelistResult.h + include/alibabacloud/sas/model/DescribeWarningExportInfoRequest.h + include/alibabacloud/sas/model/DescribeWarningExportInfoResult.h include/alibabacloud/sas/model/DescribeWarningMachinesRequest.h include/alibabacloud/sas/model/DescribeWarningMachinesResult.h include/alibabacloud/sas/model/DescribeWebLockBindListRequest.h @@ -301,6 +307,8 @@ set(sas_public_header_model include/alibabacloud/sas/model/FixCheckWarningsResult.h include/alibabacloud/sas/model/GetBackupStorageCountRequest.h include/alibabacloud/sas/model/GetBackupStorageCountResult.h + include/alibabacloud/sas/model/GetFileDetectResultRequest.h + include/alibabacloud/sas/model/GetFileDetectResultResult.h include/alibabacloud/sas/model/GetSuspiciousStatisticsRequest.h include/alibabacloud/sas/model/GetSuspiciousStatisticsResult.h include/alibabacloud/sas/model/GetVulStatisticsRequest.h @@ -426,6 +434,10 @@ set(sas_src src/model/CreateAntiBruteForceRuleResult.cc src/model/CreateBackupPolicyRequest.cc src/model/CreateBackupPolicyResult.cc + src/model/CreateFileDetectRequest.cc + src/model/CreateFileDetectResult.cc + src/model/CreateFileDetectUploadUrlRequest.cc + src/model/CreateFileDetectUploadUrlResult.cc src/model/CreateOrUpdateAssetGroupRequest.cc src/model/CreateOrUpdateAssetGroupResult.cc src/model/CreateServiceLinkedRoleRequest.cc @@ -680,6 +692,8 @@ set(sas_src src/model/DescribeVulListResult.cc src/model/DescribeVulWhitelistRequest.cc src/model/DescribeVulWhitelistResult.cc + src/model/DescribeWarningExportInfoRequest.cc + src/model/DescribeWarningExportInfoResult.cc src/model/DescribeWarningMachinesRequest.cc src/model/DescribeWarningMachinesResult.cc src/model/DescribeWebLockBindListRequest.cc @@ -696,6 +710,8 @@ set(sas_src src/model/FixCheckWarningsResult.cc src/model/GetBackupStorageCountRequest.cc src/model/GetBackupStorageCountResult.cc + src/model/GetFileDetectResultRequest.cc + src/model/GetFileDetectResultResult.cc src/model/GetSuspiciousStatisticsRequest.cc src/model/GetSuspiciousStatisticsResult.cc src/model/GetVulStatisticsRequest.cc diff --git a/sas/include/alibabacloud/sas/SasClient.h b/sas/include/alibabacloud/sas/SasClient.h index 608d7a0df..c0b11b63c 100644 --- a/sas/include/alibabacloud/sas/SasClient.h +++ b/sas/include/alibabacloud/sas/SasClient.h @@ -32,6 +32,10 @@ #include "model/CreateAntiBruteForceRuleResult.h" #include "model/CreateBackupPolicyRequest.h" #include "model/CreateBackupPolicyResult.h" +#include "model/CreateFileDetectRequest.h" +#include "model/CreateFileDetectResult.h" +#include "model/CreateFileDetectUploadUrlRequest.h" +#include "model/CreateFileDetectUploadUrlResult.h" #include "model/CreateOrUpdateAssetGroupRequest.h" #include "model/CreateOrUpdateAssetGroupResult.h" #include "model/CreateServiceLinkedRoleRequest.h" @@ -286,6 +290,8 @@ #include "model/DescribeVulListResult.h" #include "model/DescribeVulWhitelistRequest.h" #include "model/DescribeVulWhitelistResult.h" +#include "model/DescribeWarningExportInfoRequest.h" +#include "model/DescribeWarningExportInfoResult.h" #include "model/DescribeWarningMachinesRequest.h" #include "model/DescribeWarningMachinesResult.h" #include "model/DescribeWebLockBindListRequest.h" @@ -302,6 +308,8 @@ #include "model/FixCheckWarningsResult.h" #include "model/GetBackupStorageCountRequest.h" #include "model/GetBackupStorageCountResult.h" +#include "model/GetFileDetectResultRequest.h" +#include "model/GetFileDetectResultResult.h" #include "model/GetSuspiciousStatisticsRequest.h" #include "model/GetSuspiciousStatisticsResult.h" #include "model/GetVulStatisticsRequest.h" @@ -438,6 +446,12 @@ namespace AlibabaCloud typedef Outcome CreateBackupPolicyOutcome; typedef std::future CreateBackupPolicyOutcomeCallable; typedef std::function&)> CreateBackupPolicyAsyncHandler; + typedef Outcome CreateFileDetectOutcome; + typedef std::future CreateFileDetectOutcomeCallable; + typedef std::function&)> CreateFileDetectAsyncHandler; + typedef Outcome CreateFileDetectUploadUrlOutcome; + typedef std::future CreateFileDetectUploadUrlOutcomeCallable; + typedef std::function&)> CreateFileDetectUploadUrlAsyncHandler; typedef Outcome CreateOrUpdateAssetGroupOutcome; typedef std::future CreateOrUpdateAssetGroupOutcomeCallable; typedef std::function&)> CreateOrUpdateAssetGroupAsyncHandler; @@ -819,6 +833,9 @@ namespace AlibabaCloud typedef Outcome DescribeVulWhitelistOutcome; typedef std::future DescribeVulWhitelistOutcomeCallable; typedef std::function&)> DescribeVulWhitelistAsyncHandler; + typedef Outcome DescribeWarningExportInfoOutcome; + typedef std::future DescribeWarningExportInfoOutcomeCallable; + typedef std::function&)> DescribeWarningExportInfoAsyncHandler; typedef Outcome DescribeWarningMachinesOutcome; typedef std::future DescribeWarningMachinesOutcomeCallable; typedef std::function&)> DescribeWarningMachinesAsyncHandler; @@ -843,6 +860,9 @@ namespace AlibabaCloud typedef Outcome GetBackupStorageCountOutcome; typedef std::future GetBackupStorageCountOutcomeCallable; typedef std::function&)> GetBackupStorageCountAsyncHandler; + typedef Outcome GetFileDetectResultOutcome; + typedef std::future GetFileDetectResultOutcomeCallable; + typedef std::function&)> GetFileDetectResultAsyncHandler; typedef Outcome GetSuspiciousStatisticsOutcome; typedef std::future GetSuspiciousStatisticsOutcomeCallable; typedef std::function&)> GetSuspiciousStatisticsAsyncHandler; @@ -1031,6 +1051,12 @@ namespace AlibabaCloud CreateBackupPolicyOutcome createBackupPolicy(const Model::CreateBackupPolicyRequest &request)const; void createBackupPolicyAsync(const Model::CreateBackupPolicyRequest& request, const CreateBackupPolicyAsyncHandler& handler, const std::shared_ptr& context = nullptr) const; CreateBackupPolicyOutcomeCallable createBackupPolicyCallable(const Model::CreateBackupPolicyRequest& request) const; + CreateFileDetectOutcome createFileDetect(const Model::CreateFileDetectRequest &request)const; + void createFileDetectAsync(const Model::CreateFileDetectRequest& request, const CreateFileDetectAsyncHandler& handler, const std::shared_ptr& context = nullptr) const; + CreateFileDetectOutcomeCallable createFileDetectCallable(const Model::CreateFileDetectRequest& request) const; + CreateFileDetectUploadUrlOutcome createFileDetectUploadUrl(const Model::CreateFileDetectUploadUrlRequest &request)const; + void createFileDetectUploadUrlAsync(const Model::CreateFileDetectUploadUrlRequest& request, const CreateFileDetectUploadUrlAsyncHandler& handler, const std::shared_ptr& context = nullptr) const; + CreateFileDetectUploadUrlOutcomeCallable createFileDetectUploadUrlCallable(const Model::CreateFileDetectUploadUrlRequest& request) const; CreateOrUpdateAssetGroupOutcome createOrUpdateAssetGroup(const Model::CreateOrUpdateAssetGroupRequest &request)const; void createOrUpdateAssetGroupAsync(const Model::CreateOrUpdateAssetGroupRequest& request, const CreateOrUpdateAssetGroupAsyncHandler& handler, const std::shared_ptr& context = nullptr) const; CreateOrUpdateAssetGroupOutcomeCallable createOrUpdateAssetGroupCallable(const Model::CreateOrUpdateAssetGroupRequest& request) const; @@ -1412,6 +1438,9 @@ namespace AlibabaCloud DescribeVulWhitelistOutcome describeVulWhitelist(const Model::DescribeVulWhitelistRequest &request)const; void describeVulWhitelistAsync(const Model::DescribeVulWhitelistRequest& request, const DescribeVulWhitelistAsyncHandler& handler, const std::shared_ptr& context = nullptr) const; DescribeVulWhitelistOutcomeCallable describeVulWhitelistCallable(const Model::DescribeVulWhitelistRequest& request) const; + DescribeWarningExportInfoOutcome describeWarningExportInfo(const Model::DescribeWarningExportInfoRequest &request)const; + void describeWarningExportInfoAsync(const Model::DescribeWarningExportInfoRequest& request, const DescribeWarningExportInfoAsyncHandler& handler, const std::shared_ptr& context = nullptr) const; + DescribeWarningExportInfoOutcomeCallable describeWarningExportInfoCallable(const Model::DescribeWarningExportInfoRequest& request) const; DescribeWarningMachinesOutcome describeWarningMachines(const Model::DescribeWarningMachinesRequest &request)const; void describeWarningMachinesAsync(const Model::DescribeWarningMachinesRequest& request, const DescribeWarningMachinesAsyncHandler& handler, const std::shared_ptr& context = nullptr) const; DescribeWarningMachinesOutcomeCallable describeWarningMachinesCallable(const Model::DescribeWarningMachinesRequest& request) const; @@ -1436,6 +1465,9 @@ namespace AlibabaCloud GetBackupStorageCountOutcome getBackupStorageCount(const Model::GetBackupStorageCountRequest &request)const; void getBackupStorageCountAsync(const Model::GetBackupStorageCountRequest& request, const GetBackupStorageCountAsyncHandler& handler, const std::shared_ptr& context = nullptr) const; GetBackupStorageCountOutcomeCallable getBackupStorageCountCallable(const Model::GetBackupStorageCountRequest& request) const; + GetFileDetectResultOutcome getFileDetectResult(const Model::GetFileDetectResultRequest &request)const; + void getFileDetectResultAsync(const Model::GetFileDetectResultRequest& request, const GetFileDetectResultAsyncHandler& handler, const std::shared_ptr& context = nullptr) const; + GetFileDetectResultOutcomeCallable getFileDetectResultCallable(const Model::GetFileDetectResultRequest& request) const; GetSuspiciousStatisticsOutcome getSuspiciousStatistics(const Model::GetSuspiciousStatisticsRequest &request)const; void getSuspiciousStatisticsAsync(const Model::GetSuspiciousStatisticsRequest& request, const GetSuspiciousStatisticsAsyncHandler& handler, const std::shared_ptr& context = nullptr) const; GetSuspiciousStatisticsOutcomeCallable getSuspiciousStatisticsCallable(const Model::GetSuspiciousStatisticsRequest& request) const; diff --git a/sas/include/alibabacloud/sas/model/CreateFileDetectRequest.h b/sas/include/alibabacloud/sas/model/CreateFileDetectRequest.h new file mode 100644 index 000000000..d4efdb448 --- /dev/null +++ b/sas/include/alibabacloud/sas/model/CreateFileDetectRequest.h @@ -0,0 +1,51 @@ +/* + * Copyright 2009-2017 Alibaba Cloud All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#ifndef ALIBABACLOUD_SAS_MODEL_CREATEFILEDETECTREQUEST_H_ +#define ALIBABACLOUD_SAS_MODEL_CREATEFILEDETECTREQUEST_H_ + +#include +#include +#include +#include +#include + +namespace AlibabaCloud { +namespace Sas { +namespace Model { +class ALIBABACLOUD_SAS_EXPORT CreateFileDetectRequest : public RpcServiceRequest { +public: + CreateFileDetectRequest(); + ~CreateFileDetectRequest(); + std::string getHashKey() const; + void setHashKey(const std::string &hashKey); + std::string getOssKey() const; + void setOssKey(const std::string &ossKey); + int getType() const; + void setType(int type); + std::string getSourceIp() const; + void setSourceIp(const std::string &sourceIp); + +private: + std::string hashKey_; + std::string ossKey_; + int type_; + std::string sourceIp_; +}; +} // namespace Model +} // namespace Sas +} // namespace AlibabaCloud +#endif // !ALIBABACLOUD_SAS_MODEL_CREATEFILEDETECTREQUEST_H_ diff --git a/sas/include/alibabacloud/sas/model/CreateFileDetectResult.h b/sas/include/alibabacloud/sas/model/CreateFileDetectResult.h new file mode 100644 index 000000000..812617f40 --- /dev/null +++ b/sas/include/alibabacloud/sas/model/CreateFileDetectResult.h @@ -0,0 +1,51 @@ +/* + * Copyright 2009-2017 Alibaba Cloud All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#ifndef ALIBABACLOUD_SAS_MODEL_CREATEFILEDETECTRESULT_H_ +#define ALIBABACLOUD_SAS_MODEL_CREATEFILEDETECTRESULT_H_ + +#include +#include +#include +#include +#include + +namespace AlibabaCloud +{ + namespace Sas + { + namespace Model + { + class ALIBABACLOUD_SAS_EXPORT CreateFileDetectResult : public ServiceResult + { + public: + + + CreateFileDetectResult(); + explicit CreateFileDetectResult(const std::string &payload); + ~CreateFileDetectResult(); + std::string getHashKey()const; + + protected: + void parse(const std::string &payload); + private: + std::string hashKey_; + + }; + } + } +} +#endif // !ALIBABACLOUD_SAS_MODEL_CREATEFILEDETECTRESULT_H_ \ No newline at end of file diff --git a/sas/include/alibabacloud/sas/model/CreateFileDetectUploadUrlRequest.h b/sas/include/alibabacloud/sas/model/CreateFileDetectUploadUrlRequest.h new file mode 100644 index 000000000..3fb75ea94 --- /dev/null +++ b/sas/include/alibabacloud/sas/model/CreateFileDetectUploadUrlRequest.h @@ -0,0 +1,45 @@ +/* + * Copyright 2009-2017 Alibaba Cloud All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#ifndef ALIBABACLOUD_SAS_MODEL_CREATEFILEDETECTUPLOADURLREQUEST_H_ +#define ALIBABACLOUD_SAS_MODEL_CREATEFILEDETECTUPLOADURLREQUEST_H_ + +#include +#include +#include +#include +#include + +namespace AlibabaCloud { +namespace Sas { +namespace Model { +class ALIBABACLOUD_SAS_EXPORT CreateFileDetectUploadUrlRequest : public RpcServiceRequest { +public: + CreateFileDetectUploadUrlRequest(); + ~CreateFileDetectUploadUrlRequest(); + std::vector getHashKeyList() const; + void setHashKeyList(const std::vector &hashKeyList); + int getType() const; + void setType(int type); + +private: + std::vector hashKeyList_; + int type_; +}; +} // namespace Model +} // namespace Sas +} // namespace AlibabaCloud +#endif // !ALIBABACLOUD_SAS_MODEL_CREATEFILEDETECTUPLOADURLREQUEST_H_ diff --git a/sas/include/alibabacloud/sas/model/CreateFileDetectUploadUrlResult.h b/sas/include/alibabacloud/sas/model/CreateFileDetectUploadUrlResult.h new file mode 100644 index 000000000..5bbda33b9 --- /dev/null +++ b/sas/include/alibabacloud/sas/model/CreateFileDetectUploadUrlResult.h @@ -0,0 +1,67 @@ +/* + * Copyright 2009-2017 Alibaba Cloud All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#ifndef ALIBABACLOUD_SAS_MODEL_CREATEFILEDETECTUPLOADURLRESULT_H_ +#define ALIBABACLOUD_SAS_MODEL_CREATEFILEDETECTUPLOADURLRESULT_H_ + +#include +#include +#include +#include +#include + +namespace AlibabaCloud +{ + namespace Sas + { + namespace Model + { + class ALIBABACLOUD_SAS_EXPORT CreateFileDetectUploadUrlResult : public ServiceResult + { + public: + struct UploadUrList + { + struct Context + { + std::string policy; + std::string accessId; + std::string signature; + std::string ossKey; + }; + Context context; + std::string internalUrl; + std::string expire; + std::string publicUrl; + std::string hashKey; + bool fileExist; + }; + + + CreateFileDetectUploadUrlResult(); + explicit CreateFileDetectUploadUrlResult(const std::string &payload); + ~CreateFileDetectUploadUrlResult(); + std::vector getUploadUrlList()const; + + protected: + void parse(const std::string &payload); + private: + std::vector uploadUrlList_; + + }; + } + } +} +#endif // !ALIBABACLOUD_SAS_MODEL_CREATEFILEDETECTUPLOADURLRESULT_H_ \ No newline at end of file diff --git a/sas/include/alibabacloud/sas/model/DescribeAlarmEventListRequest.h b/sas/include/alibabacloud/sas/model/DescribeAlarmEventListRequest.h index b57625169..03099746b 100644 --- a/sas/include/alibabacloud/sas/model/DescribeAlarmEventListRequest.h +++ b/sas/include/alibabacloud/sas/model/DescribeAlarmEventListRequest.h @@ -30,6 +30,8 @@ class ALIBABACLOUD_SAS_EXPORT DescribeAlarmEventListRequest : public RpcServiceR public: DescribeAlarmEventListRequest(); ~DescribeAlarmEventListRequest(); + std::string getTimeEnd() const; + void setTimeEnd(const std::string &timeEnd); std::string getTargetType() const; void setTargetType(const std::string &targetType); std::string getAlarmEventType() const; @@ -64,12 +66,21 @@ public: void setCurrentPage(int currentPage); std::string getClusterId() const; void setClusterId(const std::string &clusterId); + std::string getOperateTimeEnd() const; + void setOperateTimeEnd(const std::string &operateTimeEnd); std::vector getOperateErrorCodeList() const; void setOperateErrorCodeList(const std::vector &operateErrorCodeList); + std::string getOperateTimeStart() const; + void setOperateTimeStart(const std::string &operateTimeStart); + std::string getTimeStart() const; + void setTimeStart(const std::string &timeStart); std::string getLevels() const; void setLevels(const std::string &levels); + std::string getUuids() const; + void setUuids(const std::string &uuids); private: + std::string timeEnd_; std::string targetType_; std::string alarmEventType_; std::string remark_; @@ -87,8 +98,12 @@ private: std::string dealed_; int currentPage_; std::string clusterId_; + std::string operateTimeEnd_; std::vector operateErrorCodeList_; + std::string operateTimeStart_; + std::string timeStart_; std::string levels_; + std::string uuids_; }; } // namespace Model } // namespace Sas diff --git a/sas/include/alibabacloud/sas/model/DescribeAssetSummaryResult.h b/sas/include/alibabacloud/sas/model/DescribeAssetSummaryResult.h index 6cbe1cc9b..845980669 100644 --- a/sas/include/alibabacloud/sas/model/DescribeAssetSummaryResult.h +++ b/sas/include/alibabacloud/sas/model/DescribeAssetSummaryResult.h @@ -34,6 +34,8 @@ namespace AlibabaCloud public: struct AssetsSummary { + int totalCoreAllRegion; + int totalAssetAllRegion; int totalCoreNum; }; diff --git a/sas/include/alibabacloud/sas/model/DescribeSuspEventsRequest.h b/sas/include/alibabacloud/sas/model/DescribeSuspEventsRequest.h index 885c0757f..cd7bdd5f4 100644 --- a/sas/include/alibabacloud/sas/model/DescribeSuspEventsRequest.h +++ b/sas/include/alibabacloud/sas/model/DescribeSuspEventsRequest.h @@ -30,36 +30,46 @@ class ALIBABACLOUD_SAS_EXPORT DescribeSuspEventsRequest : public RpcServiceReque public: DescribeSuspEventsRequest(); ~DescribeSuspEventsRequest(); - std::string getTargetType() const; - void setTargetType(const std::string &targetType); - std::string getRemark() const; - void setRemark(const std::string &remark); std::string getSource() const; void setSource(const std::string &source); std::string getContainerFieldName() const; void setContainerFieldName(const std::string &containerFieldName); std::string getSourceIp() const; void setSourceIp(const std::string &sourceIp); - std::string getContainerFieldValue() const; - void setContainerFieldValue(const std::string &containerFieldValue); std::string getEventNames() const; void setEventNames(const std::string &eventNames); - std::string getPageSize() const; - void setPageSize(const std::string &pageSize); std::string getFrom() const; void setFrom(const std::string &from); long getId() const; void setId(long id); std::string getTacticId() const; void setTacticId(const std::string &tacticId); - std::string getLang() const; - void setLang(const std::string &lang); std::string getAlarmUniqueInfo() const; void setAlarmUniqueInfo(const std::string &alarmUniqueInfo); std::string getUniqueInfo() const; void setUniqueInfo(const std::string &uniqueInfo); long getGroupId() const; void setGroupId(long groupId); + std::string getOperateTimeEnd() const; + void setOperateTimeEnd(const std::string &operateTimeEnd); + std::string getName() const; + void setName(const std::string &name); + std::string getStatus() const; + void setStatus(const std::string &status); + std::string getUuids() const; + void setUuids(const std::string &uuids); + std::string getTimeEnd() const; + void setTimeEnd(const std::string &timeEnd); + std::string getTargetType() const; + void setTargetType(const std::string &targetType); + std::string getRemark() const; + void setRemark(const std::string &remark); + std::string getContainerFieldValue() const; + void setContainerFieldValue(const std::string &containerFieldValue); + std::string getPageSize() const; + void setPageSize(const std::string &pageSize); + std::string getLang() const; + void setLang(const std::string &lang); std::string getDealed() const; void setDealed(const std::string &dealed); std::string getCurrentPage() const; @@ -68,42 +78,44 @@ public: void setClusterId(const std::string &clusterId); std::vector getOperateErrorCodeList() const; void setOperateErrorCodeList(const std::vector &operateErrorCodeList); - std::string getName() const; - void setName(const std::string &name); + std::string getOperateTimeStart() const; + void setOperateTimeStart(const std::string &operateTimeStart); + std::string getTimeStart() const; + void setTimeStart(const std::string &timeStart); std::string getLevels() const; void setLevels(const std::string &levels); std::string getParentEventTypes() const; void setParentEventTypes(const std::string &parentEventTypes); - std::string getStatus() const; - void setStatus(const std::string &status); - std::string getUuids() const; - void setUuids(const std::string &uuids); private: - std::string targetType_; - std::string remark_; std::string source_; std::string containerFieldName_; std::string sourceIp_; - std::string containerFieldValue_; std::string eventNames_; - std::string pageSize_; std::string from_; long id_; std::string tacticId_; - std::string lang_; std::string alarmUniqueInfo_; std::string uniqueInfo_; long groupId_; + std::string operateTimeEnd_; + std::string name_; + std::string status_; + std::string uuids_; + std::string timeEnd_; + std::string targetType_; + std::string remark_; + std::string containerFieldValue_; + std::string pageSize_; + std::string lang_; std::string dealed_; std::string currentPage_; std::string clusterId_; std::vector operateErrorCodeList_; - std::string name_; + std::string operateTimeStart_; + std::string timeStart_; std::string levels_; std::string parentEventTypes_; - std::string status_; - std::string uuids_; }; } // namespace Model } // namespace Sas diff --git a/sas/include/alibabacloud/sas/model/DescribeVersionConfigResult.h b/sas/include/alibabacloud/sas/model/DescribeVersionConfigResult.h index a618841f8..1a8d6cc31 100644 --- a/sas/include/alibabacloud/sas/model/DescribeVersionConfigResult.h +++ b/sas/include/alibabacloud/sas/model/DescribeVersionConfigResult.h @@ -42,6 +42,7 @@ namespace AlibabaCloud long getAppWhiteListAuthCount()const; int getLogTime()const; int getSasLog()const; + long getOpenTime()const; int getVersion()const; int getAvdsFlag()const; int getHighestVersion()const; @@ -65,6 +66,7 @@ namespace AlibabaCloud int getMVAuthCount()const; long getGmtCreate()const; long getReleaseTime()const; + bool getIsNewContainerVersion()const; int getMVUnusedAuthCount()const; int getIsTrialVersion()const; int getAppWhiteList()const; @@ -77,6 +79,7 @@ namespace AlibabaCloud long appWhiteListAuthCount_; int logTime_; int sasLog_; + long openTime_; int version_; int avdsFlag_; int highestVersion_; @@ -100,6 +103,7 @@ namespace AlibabaCloud int mVAuthCount_; long gmtCreate_; long releaseTime_; + bool isNewContainerVersion_; int mVUnusedAuthCount_; int isTrialVersion_; int appWhiteList_; diff --git a/sas/include/alibabacloud/sas/model/DescribeVulDetailsResult.h b/sas/include/alibabacloud/sas/model/DescribeVulDetailsResult.h index 2c0a77d1d..7013da417 100644 --- a/sas/include/alibabacloud/sas/model/DescribeVulDetailsResult.h +++ b/sas/include/alibabacloud/sas/model/DescribeVulDetailsResult.h @@ -51,6 +51,7 @@ namespace AlibabaCloud std::string title; std::string cveId; std::string vendor; + std::string otherId; std::string cnvdId; std::string complexity; long pocCreateTime; diff --git a/sas/include/alibabacloud/sas/model/DescribeWarningExportInfoRequest.h b/sas/include/alibabacloud/sas/model/DescribeWarningExportInfoRequest.h new file mode 100644 index 000000000..355964ddd --- /dev/null +++ b/sas/include/alibabacloud/sas/model/DescribeWarningExportInfoRequest.h @@ -0,0 +1,45 @@ +/* + * Copyright 2009-2017 Alibaba Cloud All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#ifndef ALIBABACLOUD_SAS_MODEL_DESCRIBEWARNINGEXPORTINFOREQUEST_H_ +#define ALIBABACLOUD_SAS_MODEL_DESCRIBEWARNINGEXPORTINFOREQUEST_H_ + +#include +#include +#include +#include +#include + +namespace AlibabaCloud { +namespace Sas { +namespace Model { +class ALIBABACLOUD_SAS_EXPORT DescribeWarningExportInfoRequest : public RpcServiceRequest { +public: + DescribeWarningExportInfoRequest(); + ~DescribeWarningExportInfoRequest(); + std::string getSourceIp() const; + void setSourceIp(const std::string &sourceIp); + long getExportId() const; + void setExportId(long exportId); + +private: + std::string sourceIp_; + long exportId_; +}; +} // namespace Model +} // namespace Sas +} // namespace AlibabaCloud +#endif // !ALIBABACLOUD_SAS_MODEL_DESCRIBEWARNINGEXPORTINFOREQUEST_H_ diff --git a/sas/include/alibabacloud/sas/model/DescribeWarningExportInfoResult.h b/sas/include/alibabacloud/sas/model/DescribeWarningExportInfoResult.h new file mode 100644 index 000000000..cfe46cbd7 --- /dev/null +++ b/sas/include/alibabacloud/sas/model/DescribeWarningExportInfoResult.h @@ -0,0 +1,65 @@ +/* + * Copyright 2009-2017 Alibaba Cloud All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#ifndef ALIBABACLOUD_SAS_MODEL_DESCRIBEWARNINGEXPORTINFORESULT_H_ +#define ALIBABACLOUD_SAS_MODEL_DESCRIBEWARNINGEXPORTINFORESULT_H_ + +#include +#include +#include +#include +#include + +namespace AlibabaCloud +{ + namespace Sas + { + namespace Model + { + class ALIBABACLOUD_SAS_EXPORT DescribeWarningExportInfoResult : public ServiceResult + { + public: + + + DescribeWarningExportInfoResult(); + explicit DescribeWarningExportInfoResult(const std::string &payload); + ~DescribeWarningExportInfoResult(); + int getProgress()const; + int getTotalCount()const; + std::string getMessage()const; + std::string getFileName()const; + std::string getExportStatus()const; + int getCurrentCount()const; + long getId()const; + std::string getLink()const; + + protected: + void parse(const std::string &payload); + private: + int progress_; + int totalCount_; + std::string message_; + std::string fileName_; + std::string exportStatus_; + int currentCount_; + long id_; + std::string link_; + + }; + } + } +} +#endif // !ALIBABACLOUD_SAS_MODEL_DESCRIBEWARNINGEXPORTINFORESULT_H_ \ No newline at end of file diff --git a/sas/include/alibabacloud/sas/model/GetFileDetectResultRequest.h b/sas/include/alibabacloud/sas/model/GetFileDetectResultRequest.h new file mode 100644 index 000000000..7f48dc809 --- /dev/null +++ b/sas/include/alibabacloud/sas/model/GetFileDetectResultRequest.h @@ -0,0 +1,48 @@ +/* + * Copyright 2009-2017 Alibaba Cloud All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#ifndef ALIBABACLOUD_SAS_MODEL_GETFILEDETECTRESULTREQUEST_H_ +#define ALIBABACLOUD_SAS_MODEL_GETFILEDETECTRESULTREQUEST_H_ + +#include +#include +#include +#include +#include + +namespace AlibabaCloud { +namespace Sas { +namespace Model { +class ALIBABACLOUD_SAS_EXPORT GetFileDetectResultRequest : public RpcServiceRequest { +public: + GetFileDetectResultRequest(); + ~GetFileDetectResultRequest(); + std::vector getHashKeyList() const; + void setHashKeyList(const std::vector &hashKeyList); + int getType() const; + void setType(int type); + std::string getSourceIp() const; + void setSourceIp(const std::string &sourceIp); + +private: + std::vector hashKeyList_; + int type_; + std::string sourceIp_; +}; +} // namespace Model +} // namespace Sas +} // namespace AlibabaCloud +#endif // !ALIBABACLOUD_SAS_MODEL_GETFILEDETECTRESULTREQUEST_H_ diff --git a/sas/include/alibabacloud/sas/model/GetFileDetectResultResult.h b/sas/include/alibabacloud/sas/model/GetFileDetectResultResult.h new file mode 100644 index 000000000..3635beec6 --- /dev/null +++ b/sas/include/alibabacloud/sas/model/GetFileDetectResultResult.h @@ -0,0 +1,61 @@ +/* + * Copyright 2009-2017 Alibaba Cloud All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#ifndef ALIBABACLOUD_SAS_MODEL_GETFILEDETECTRESULTRESULT_H_ +#define ALIBABACLOUD_SAS_MODEL_GETFILEDETECTRESULTRESULT_H_ + +#include +#include +#include +#include +#include + +namespace AlibabaCloud +{ + namespace Sas + { + namespace Model + { + class ALIBABACLOUD_SAS_EXPORT GetFileDetectResultResult : public ServiceResult + { + public: + struct Result + { + struct Ext + { + std::string virusName; + }; + Ext ext; + std::string hashKey; + int result; + }; + + + GetFileDetectResultResult(); + explicit GetFileDetectResultResult(const std::string &payload); + ~GetFileDetectResultResult(); + std::vector getResultList()const; + + protected: + void parse(const std::string &payload); + private: + std::vector resultList_; + + }; + } + } +} +#endif // !ALIBABACLOUD_SAS_MODEL_GETFILEDETECTRESULTRESULT_H_ \ No newline at end of file diff --git a/sas/include/alibabacloud/sas/model/ModifyOpenLogShipperRequest.h b/sas/include/alibabacloud/sas/model/ModifyOpenLogShipperRequest.h index b664c961b..a0fda5946 100644 --- a/sas/include/alibabacloud/sas/model/ModifyOpenLogShipperRequest.h +++ b/sas/include/alibabacloud/sas/model/ModifyOpenLogShipperRequest.h @@ -28,16 +28,34 @@ namespace Sas { namespace Model { class ALIBABACLOUD_SAS_EXPORT ModifyOpenLogShipperRequest : public RpcServiceRequest { public: + struct LogMetaList { + int hotTtl; + int ttl; + std::string configLogStore; + std::string status; + }; ModifyOpenLogShipperRequest(); ~ModifyOpenLogShipperRequest(); + std::vector getLogMetaList() const; + void setLogMetaList(const std::vector &logMetaList); + int getTtl() const; + void setTtl(int ttl); std::string getSourceIp() const; void setSourceIp(const std::string &sourceIp); + int getHotTtl() const; + void setHotTtl(int hotTtl); std::string getFrom() const; void setFrom(const std::string &from); + std::string getTargetRegionId() const; + void setTargetRegionId(const std::string &targetRegionId); private: + std::vector logMetaList_; + int ttl_; std::string sourceIp_; + int hotTtl_; std::string from_; + std::string targetRegionId_; }; } // namespace Model } // namespace Sas diff --git a/sas/src/SasClient.cc b/sas/src/SasClient.cc index dd485ddfe..db251cc50 100644 --- a/sas/src/SasClient.cc +++ b/sas/src/SasClient.cc @@ -231,6 +231,78 @@ SasClient::CreateBackupPolicyOutcomeCallable SasClient::createBackupPolicyCallab return task->get_future(); } +SasClient::CreateFileDetectOutcome SasClient::createFileDetect(const CreateFileDetectRequest &request) const +{ + auto endpointOutcome = endpointProvider_->getEndpoint(); + if (!endpointOutcome.isSuccess()) + return CreateFileDetectOutcome(endpointOutcome.error()); + + auto outcome = makeRequest(endpointOutcome.result(), request); + + if (outcome.isSuccess()) + return CreateFileDetectOutcome(CreateFileDetectResult(outcome.result())); + else + return CreateFileDetectOutcome(outcome.error()); +} + +void SasClient::createFileDetectAsync(const CreateFileDetectRequest& request, const CreateFileDetectAsyncHandler& handler, const std::shared_ptr& context) const +{ + auto fn = [this, request, handler, context]() + { + handler(this, request, createFileDetect(request), context); + }; + + asyncExecute(new Runnable(fn)); +} + +SasClient::CreateFileDetectOutcomeCallable SasClient::createFileDetectCallable(const CreateFileDetectRequest &request) const +{ + auto task = std::make_shared>( + [this, request]() + { + return this->createFileDetect(request); + }); + + asyncExecute(new Runnable([task]() { (*task)(); })); + return task->get_future(); +} + +SasClient::CreateFileDetectUploadUrlOutcome SasClient::createFileDetectUploadUrl(const CreateFileDetectUploadUrlRequest &request) const +{ + auto endpointOutcome = endpointProvider_->getEndpoint(); + if (!endpointOutcome.isSuccess()) + return CreateFileDetectUploadUrlOutcome(endpointOutcome.error()); + + auto outcome = makeRequest(endpointOutcome.result(), request); + + if (outcome.isSuccess()) + return CreateFileDetectUploadUrlOutcome(CreateFileDetectUploadUrlResult(outcome.result())); + else + return CreateFileDetectUploadUrlOutcome(outcome.error()); +} + +void SasClient::createFileDetectUploadUrlAsync(const CreateFileDetectUploadUrlRequest& request, const CreateFileDetectUploadUrlAsyncHandler& handler, const std::shared_ptr& context) const +{ + auto fn = [this, request, handler, context]() + { + handler(this, request, createFileDetectUploadUrl(request), context); + }; + + asyncExecute(new Runnable(fn)); +} + +SasClient::CreateFileDetectUploadUrlOutcomeCallable SasClient::createFileDetectUploadUrlCallable(const CreateFileDetectUploadUrlRequest &request) const +{ + auto task = std::make_shared>( + [this, request]() + { + return this->createFileDetectUploadUrl(request); + }); + + asyncExecute(new Runnable([task]() { (*task)(); })); + return task->get_future(); +} + SasClient::CreateOrUpdateAssetGroupOutcome SasClient::createOrUpdateAssetGroup(const CreateOrUpdateAssetGroupRequest &request) const { auto endpointOutcome = endpointProvider_->getEndpoint(); @@ -4803,6 +4875,42 @@ SasClient::DescribeVulWhitelistOutcomeCallable SasClient::describeVulWhitelistCa return task->get_future(); } +SasClient::DescribeWarningExportInfoOutcome SasClient::describeWarningExportInfo(const DescribeWarningExportInfoRequest &request) const +{ + auto endpointOutcome = endpointProvider_->getEndpoint(); + if (!endpointOutcome.isSuccess()) + return DescribeWarningExportInfoOutcome(endpointOutcome.error()); + + auto outcome = makeRequest(endpointOutcome.result(), request); + + if (outcome.isSuccess()) + return DescribeWarningExportInfoOutcome(DescribeWarningExportInfoResult(outcome.result())); + else + return DescribeWarningExportInfoOutcome(outcome.error()); +} + +void SasClient::describeWarningExportInfoAsync(const DescribeWarningExportInfoRequest& request, const DescribeWarningExportInfoAsyncHandler& handler, const std::shared_ptr& context) const +{ + auto fn = [this, request, handler, context]() + { + handler(this, request, describeWarningExportInfo(request), context); + }; + + asyncExecute(new Runnable(fn)); +} + +SasClient::DescribeWarningExportInfoOutcomeCallable SasClient::describeWarningExportInfoCallable(const DescribeWarningExportInfoRequest &request) const +{ + auto task = std::make_shared>( + [this, request]() + { + return this->describeWarningExportInfo(request); + }); + + asyncExecute(new Runnable([task]() { (*task)(); })); + return task->get_future(); +} + SasClient::DescribeWarningMachinesOutcome SasClient::describeWarningMachines(const DescribeWarningMachinesRequest &request) const { auto endpointOutcome = endpointProvider_->getEndpoint(); @@ -5091,6 +5199,42 @@ SasClient::GetBackupStorageCountOutcomeCallable SasClient::getBackupStorageCount return task->get_future(); } +SasClient::GetFileDetectResultOutcome SasClient::getFileDetectResult(const GetFileDetectResultRequest &request) const +{ + auto endpointOutcome = endpointProvider_->getEndpoint(); + if (!endpointOutcome.isSuccess()) + return GetFileDetectResultOutcome(endpointOutcome.error()); + + auto outcome = makeRequest(endpointOutcome.result(), request); + + if (outcome.isSuccess()) + return GetFileDetectResultOutcome(GetFileDetectResultResult(outcome.result())); + else + return GetFileDetectResultOutcome(outcome.error()); +} + +void SasClient::getFileDetectResultAsync(const GetFileDetectResultRequest& request, const GetFileDetectResultAsyncHandler& handler, const std::shared_ptr& context) const +{ + auto fn = [this, request, handler, context]() + { + handler(this, request, getFileDetectResult(request), context); + }; + + asyncExecute(new Runnable(fn)); +} + +SasClient::GetFileDetectResultOutcomeCallable SasClient::getFileDetectResultCallable(const GetFileDetectResultRequest &request) const +{ + auto task = std::make_shared>( + [this, request]() + { + return this->getFileDetectResult(request); + }); + + asyncExecute(new Runnable([task]() { (*task)(); })); + return task->get_future(); +} + SasClient::GetSuspiciousStatisticsOutcome SasClient::getSuspiciousStatistics(const GetSuspiciousStatisticsRequest &request) const { auto endpointOutcome = endpointProvider_->getEndpoint(); diff --git a/sas/src/model/CreateFileDetectRequest.cc b/sas/src/model/CreateFileDetectRequest.cc new file mode 100644 index 000000000..1025379e9 --- /dev/null +++ b/sas/src/model/CreateFileDetectRequest.cc @@ -0,0 +1,63 @@ +/* + * Copyright 2009-2017 Alibaba Cloud All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#include + +using AlibabaCloud::Sas::Model::CreateFileDetectRequest; + +CreateFileDetectRequest::CreateFileDetectRequest() + : RpcServiceRequest("sas", "2018-12-03", "CreateFileDetect") { + setMethod(HttpRequest::Method::Post); +} + +CreateFileDetectRequest::~CreateFileDetectRequest() {} + +std::string CreateFileDetectRequest::getHashKey() const { + return hashKey_; +} + +void CreateFileDetectRequest::setHashKey(const std::string &hashKey) { + hashKey_ = hashKey; + setParameter(std::string("HashKey"), hashKey); +} + +std::string CreateFileDetectRequest::getOssKey() const { + return ossKey_; +} + +void CreateFileDetectRequest::setOssKey(const std::string &ossKey) { + ossKey_ = ossKey; + setParameter(std::string("OssKey"), ossKey); +} + +int CreateFileDetectRequest::getType() const { + return type_; +} + +void CreateFileDetectRequest::setType(int type) { + type_ = type; + setParameter(std::string("Type"), std::to_string(type)); +} + +std::string CreateFileDetectRequest::getSourceIp() const { + return sourceIp_; +} + +void CreateFileDetectRequest::setSourceIp(const std::string &sourceIp) { + sourceIp_ = sourceIp; + setParameter(std::string("SourceIp"), sourceIp); +} + diff --git a/sas/src/model/CreateFileDetectResult.cc b/sas/src/model/CreateFileDetectResult.cc new file mode 100644 index 000000000..7f4329521 --- /dev/null +++ b/sas/src/model/CreateFileDetectResult.cc @@ -0,0 +1,51 @@ +/* + * Copyright 2009-2017 Alibaba Cloud All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#include +#include + +using namespace AlibabaCloud::Sas; +using namespace AlibabaCloud::Sas::Model; + +CreateFileDetectResult::CreateFileDetectResult() : + ServiceResult() +{} + +CreateFileDetectResult::CreateFileDetectResult(const std::string &payload) : + ServiceResult() +{ + parse(payload); +} + +CreateFileDetectResult::~CreateFileDetectResult() +{} + +void CreateFileDetectResult::parse(const std::string &payload) +{ + Json::Reader reader; + Json::Value value; + reader.parse(payload, value); + setRequestId(value["RequestId"].asString()); + if(!value["HashKey"].isNull()) + hashKey_ = value["HashKey"].asString(); + +} + +std::string CreateFileDetectResult::getHashKey()const +{ + return hashKey_; +} + diff --git a/sas/src/model/CreateFileDetectUploadUrlRequest.cc b/sas/src/model/CreateFileDetectUploadUrlRequest.cc new file mode 100644 index 000000000..2e9ec17c1 --- /dev/null +++ b/sas/src/model/CreateFileDetectUploadUrlRequest.cc @@ -0,0 +1,44 @@ +/* + * Copyright 2009-2017 Alibaba Cloud All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#include + +using AlibabaCloud::Sas::Model::CreateFileDetectUploadUrlRequest; + +CreateFileDetectUploadUrlRequest::CreateFileDetectUploadUrlRequest() + : RpcServiceRequest("sas", "2018-12-03", "CreateFileDetectUploadUrl") { + setMethod(HttpRequest::Method::Post); +} + +CreateFileDetectUploadUrlRequest::~CreateFileDetectUploadUrlRequest() {} + +std::vector CreateFileDetectUploadUrlRequest::getHashKeyList() const { + return hashKeyList_; +} + +void CreateFileDetectUploadUrlRequest::setHashKeyList(const std::vector &hashKeyList) { + hashKeyList_ = hashKeyList; +} + +int CreateFileDetectUploadUrlRequest::getType() const { + return type_; +} + +void CreateFileDetectUploadUrlRequest::setType(int type) { + type_ = type; + setParameter(std::string("Type"), std::to_string(type)); +} + diff --git a/sas/src/model/CreateFileDetectUploadUrlResult.cc b/sas/src/model/CreateFileDetectUploadUrlResult.cc new file mode 100644 index 000000000..738396766 --- /dev/null +++ b/sas/src/model/CreateFileDetectUploadUrlResult.cc @@ -0,0 +1,74 @@ +/* + * Copyright 2009-2017 Alibaba Cloud All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#include +#include + +using namespace AlibabaCloud::Sas; +using namespace AlibabaCloud::Sas::Model; + +CreateFileDetectUploadUrlResult::CreateFileDetectUploadUrlResult() : + ServiceResult() +{} + +CreateFileDetectUploadUrlResult::CreateFileDetectUploadUrlResult(const std::string &payload) : + ServiceResult() +{ + parse(payload); +} + +CreateFileDetectUploadUrlResult::~CreateFileDetectUploadUrlResult() +{} + +void CreateFileDetectUploadUrlResult::parse(const std::string &payload) +{ + Json::Reader reader; + Json::Value value; + reader.parse(payload, value); + setRequestId(value["RequestId"].asString()); + auto allUploadUrlListNode = value["UploadUrlList"]["UploadUrList"]; + for (auto valueUploadUrlListUploadUrList : allUploadUrlListNode) + { + UploadUrList uploadUrlListObject; + if(!valueUploadUrlListUploadUrList["PublicUrl"].isNull()) + uploadUrlListObject.publicUrl = valueUploadUrlListUploadUrList["PublicUrl"].asString(); + if(!valueUploadUrlListUploadUrList["InternalUrl"].isNull()) + uploadUrlListObject.internalUrl = valueUploadUrlListUploadUrList["InternalUrl"].asString(); + if(!valueUploadUrlListUploadUrList["Expire"].isNull()) + uploadUrlListObject.expire = valueUploadUrlListUploadUrList["Expire"].asString(); + if(!valueUploadUrlListUploadUrList["FileExist"].isNull()) + uploadUrlListObject.fileExist = valueUploadUrlListUploadUrList["FileExist"].asString() == "true"; + if(!valueUploadUrlListUploadUrList["HashKey"].isNull()) + uploadUrlListObject.hashKey = valueUploadUrlListUploadUrList["HashKey"].asString(); + auto contextNode = value["Context"]; + if(!contextNode["AccessId"].isNull()) + uploadUrlListObject.context.accessId = contextNode["AccessId"].asString(); + if(!contextNode["Policy"].isNull()) + uploadUrlListObject.context.policy = contextNode["Policy"].asString(); + if(!contextNode["Signature"].isNull()) + uploadUrlListObject.context.signature = contextNode["Signature"].asString(); + if(!contextNode["OssKey"].isNull()) + uploadUrlListObject.context.ossKey = contextNode["OssKey"].asString(); + uploadUrlList_.push_back(uploadUrlListObject); + } + +} + +std::vector CreateFileDetectUploadUrlResult::getUploadUrlList()const +{ + return uploadUrlList_; +} + diff --git a/sas/src/model/DescribeAlarmEventListRequest.cc b/sas/src/model/DescribeAlarmEventListRequest.cc index 5e7597276..f19a6151e 100644 --- a/sas/src/model/DescribeAlarmEventListRequest.cc +++ b/sas/src/model/DescribeAlarmEventListRequest.cc @@ -25,6 +25,15 @@ DescribeAlarmEventListRequest::DescribeAlarmEventListRequest() DescribeAlarmEventListRequest::~DescribeAlarmEventListRequest() {} +std::string DescribeAlarmEventListRequest::getTimeEnd() const { + return timeEnd_; +} + +void DescribeAlarmEventListRequest::setTimeEnd(const std::string &timeEnd) { + timeEnd_ = timeEnd; + setParameter(std::string("TimeEnd"), timeEnd); +} + std::string DescribeAlarmEventListRequest::getTargetType() const { return targetType_; } @@ -178,6 +187,15 @@ void DescribeAlarmEventListRequest::setClusterId(const std::string &clusterId) { setParameter(std::string("ClusterId"), clusterId); } +std::string DescribeAlarmEventListRequest::getOperateTimeEnd() const { + return operateTimeEnd_; +} + +void DescribeAlarmEventListRequest::setOperateTimeEnd(const std::string &operateTimeEnd) { + operateTimeEnd_ = operateTimeEnd; + setParameter(std::string("OperateTimeEnd"), operateTimeEnd); +} + std::vector DescribeAlarmEventListRequest::getOperateErrorCodeList() const { return operateErrorCodeList_; } @@ -186,6 +204,24 @@ void DescribeAlarmEventListRequest::setOperateErrorCodeList(const std::vector + +using AlibabaCloud::Sas::Model::DescribeWarningExportInfoRequest; + +DescribeWarningExportInfoRequest::DescribeWarningExportInfoRequest() + : RpcServiceRequest("sas", "2018-12-03", "DescribeWarningExportInfo") { + setMethod(HttpRequest::Method::Post); +} + +DescribeWarningExportInfoRequest::~DescribeWarningExportInfoRequest() {} + +std::string DescribeWarningExportInfoRequest::getSourceIp() const { + return sourceIp_; +} + +void DescribeWarningExportInfoRequest::setSourceIp(const std::string &sourceIp) { + sourceIp_ = sourceIp; + setParameter(std::string("SourceIp"), sourceIp); +} + +long DescribeWarningExportInfoRequest::getExportId() const { + return exportId_; +} + +void DescribeWarningExportInfoRequest::setExportId(long exportId) { + exportId_ = exportId; + setParameter(std::string("ExportId"), std::to_string(exportId)); +} + diff --git a/sas/src/model/DescribeWarningExportInfoResult.cc b/sas/src/model/DescribeWarningExportInfoResult.cc new file mode 100644 index 000000000..3ccbbd288 --- /dev/null +++ b/sas/src/model/DescribeWarningExportInfoResult.cc @@ -0,0 +1,100 @@ +/* + * Copyright 2009-2017 Alibaba Cloud All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#include +#include + +using namespace AlibabaCloud::Sas; +using namespace AlibabaCloud::Sas::Model; + +DescribeWarningExportInfoResult::DescribeWarningExportInfoResult() : + ServiceResult() +{} + +DescribeWarningExportInfoResult::DescribeWarningExportInfoResult(const std::string &payload) : + ServiceResult() +{ + parse(payload); +} + +DescribeWarningExportInfoResult::~DescribeWarningExportInfoResult() +{} + +void DescribeWarningExportInfoResult::parse(const std::string &payload) +{ + Json::Reader reader; + Json::Value value; + reader.parse(payload, value); + setRequestId(value["RequestId"].asString()); + if(!value["Link"].isNull()) + link_ = value["Link"].asString(); + if(!value["Progress"].isNull()) + progress_ = std::stoi(value["Progress"].asString()); + if(!value["CurrentCount"].isNull()) + currentCount_ = std::stoi(value["CurrentCount"].asString()); + if(!value["Message"].isNull()) + message_ = value["Message"].asString(); + if(!value["FileName"].isNull()) + fileName_ = value["FileName"].asString(); + if(!value["TotalCount"].isNull()) + totalCount_ = std::stoi(value["TotalCount"].asString()); + if(!value["ExportStatus"].isNull()) + exportStatus_ = value["ExportStatus"].asString(); + if(!value["Id"].isNull()) + id_ = std::stol(value["Id"].asString()); + +} + +int DescribeWarningExportInfoResult::getProgress()const +{ + return progress_; +} + +int DescribeWarningExportInfoResult::getTotalCount()const +{ + return totalCount_; +} + +std::string DescribeWarningExportInfoResult::getMessage()const +{ + return message_; +} + +std::string DescribeWarningExportInfoResult::getFileName()const +{ + return fileName_; +} + +std::string DescribeWarningExportInfoResult::getExportStatus()const +{ + return exportStatus_; +} + +int DescribeWarningExportInfoResult::getCurrentCount()const +{ + return currentCount_; +} + +long DescribeWarningExportInfoResult::getId()const +{ + return id_; +} + +std::string DescribeWarningExportInfoResult::getLink()const +{ + return link_; +} + diff --git a/sas/src/model/GetFileDetectResultRequest.cc b/sas/src/model/GetFileDetectResultRequest.cc new file mode 100644 index 000000000..f79982a2f --- /dev/null +++ b/sas/src/model/GetFileDetectResultRequest.cc @@ -0,0 +1,53 @@ +/* + * Copyright 2009-2017 Alibaba Cloud All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#include + +using AlibabaCloud::Sas::Model::GetFileDetectResultRequest; + +GetFileDetectResultRequest::GetFileDetectResultRequest() + : RpcServiceRequest("sas", "2018-12-03", "GetFileDetectResult") { + setMethod(HttpRequest::Method::Post); +} + +GetFileDetectResultRequest::~GetFileDetectResultRequest() {} + +std::vector GetFileDetectResultRequest::getHashKeyList() const { + return hashKeyList_; +} + +void GetFileDetectResultRequest::setHashKeyList(const std::vector &hashKeyList) { + hashKeyList_ = hashKeyList; +} + +int GetFileDetectResultRequest::getType() const { + return type_; +} + +void GetFileDetectResultRequest::setType(int type) { + type_ = type; + setParameter(std::string("Type"), std::to_string(type)); +} + +std::string GetFileDetectResultRequest::getSourceIp() const { + return sourceIp_; +} + +void GetFileDetectResultRequest::setSourceIp(const std::string &sourceIp) { + sourceIp_ = sourceIp; + setParameter(std::string("SourceIp"), sourceIp); +} + diff --git a/sas/src/model/GetFileDetectResultResult.cc b/sas/src/model/GetFileDetectResultResult.cc new file mode 100644 index 000000000..a0e1efa4e --- /dev/null +++ b/sas/src/model/GetFileDetectResultResult.cc @@ -0,0 +1,62 @@ +/* + * Copyright 2009-2017 Alibaba Cloud All rights reserved. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#include +#include + +using namespace AlibabaCloud::Sas; +using namespace AlibabaCloud::Sas::Model; + +GetFileDetectResultResult::GetFileDetectResultResult() : + ServiceResult() +{} + +GetFileDetectResultResult::GetFileDetectResultResult(const std::string &payload) : + ServiceResult() +{ + parse(payload); +} + +GetFileDetectResultResult::~GetFileDetectResultResult() +{} + +void GetFileDetectResultResult::parse(const std::string &payload) +{ + Json::Reader reader; + Json::Value value; + reader.parse(payload, value); + setRequestId(value["RequestId"].asString()); + auto allResultListNode = value["ResultList"]["Result"]; + for (auto valueResultListResult : allResultListNode) + { + Result resultListObject; + if(!valueResultListResult["Result"].isNull()) + resultListObject.result = std::stoi(valueResultListResult["Result"].asString()); + if(!valueResultListResult["HashKey"].isNull()) + resultListObject.hashKey = valueResultListResult["HashKey"].asString(); + auto extNode = value["Ext"]; + if(!extNode["VirusName"].isNull()) + resultListObject.ext.virusName = extNode["VirusName"].asString(); + resultList_.push_back(resultListObject); + } + +} + +std::vector GetFileDetectResultResult::getResultList()const +{ + return resultList_; +} + diff --git a/sas/src/model/ModifyOpenLogShipperRequest.cc b/sas/src/model/ModifyOpenLogShipperRequest.cc index 79d2baa41..0407440d8 100644 --- a/sas/src/model/ModifyOpenLogShipperRequest.cc +++ b/sas/src/model/ModifyOpenLogShipperRequest.cc @@ -25,6 +25,31 @@ ModifyOpenLogShipperRequest::ModifyOpenLogShipperRequest() ModifyOpenLogShipperRequest::~ModifyOpenLogShipperRequest() {} +std::vector ModifyOpenLogShipperRequest::getLogMetaList() const { + return logMetaList_; +} + +void ModifyOpenLogShipperRequest::setLogMetaList(const std::vector &logMetaList) { + logMetaList_ = logMetaList; + for(int dep1 = 0; dep1 != logMetaList.size(); dep1++) { + auto logMetaListObj = logMetaList.at(dep1); + std::string logMetaListObjStr = std::string("LogMetaList") + "." + std::to_string(dep1 + 1); + setParameter(logMetaListObjStr + ".HotTtl", std::to_string(logMetaListObj.hotTtl)); + setParameter(logMetaListObjStr + ".Ttl", std::to_string(logMetaListObj.ttl)); + setParameter(logMetaListObjStr + ".ConfigLogStore", logMetaListObj.configLogStore); + setParameter(logMetaListObjStr + ".Status", logMetaListObj.status); + } +} + +int ModifyOpenLogShipperRequest::getTtl() const { + return ttl_; +} + +void ModifyOpenLogShipperRequest::setTtl(int ttl) { + ttl_ = ttl; + setParameter(std::string("Ttl"), std::to_string(ttl)); +} + std::string ModifyOpenLogShipperRequest::getSourceIp() const { return sourceIp_; } @@ -34,6 +59,15 @@ void ModifyOpenLogShipperRequest::setSourceIp(const std::string &sourceIp) { setParameter(std::string("SourceIp"), sourceIp); } +int ModifyOpenLogShipperRequest::getHotTtl() const { + return hotTtl_; +} + +void ModifyOpenLogShipperRequest::setHotTtl(int hotTtl) { + hotTtl_ = hotTtl; + setParameter(std::string("HotTtl"), std::to_string(hotTtl)); +} + std::string ModifyOpenLogShipperRequest::getFrom() const { return from_; } @@ -43,3 +77,12 @@ void ModifyOpenLogShipperRequest::setFrom(const std::string &from) { setParameter(std::string("From"), from); } +std::string ModifyOpenLogShipperRequest::getTargetRegionId() const { + return targetRegionId_; +} + +void ModifyOpenLogShipperRequest::setTargetRegionId(const std::string &targetRegionId) { + targetRegionId_ = targetRegionId; + setParameter(std::string("TargetRegionId"), targetRegionId); +} +