PluginProbe
Media Cloud Sync / 1.0.2
Media Cloud Sync v1.0.2
1.4.1 1.4.0 1.3.12 1.3.11 1.3.10 trunk 1.0.0 1.0.1 1.0.2 1.0.3 1.1.0 1.1.1 1.2.0 1.2.10 1.2.11 1.2.12 1.2.13 1.2.2 1.2.3 1.2.4 1.2.5 1.2.6 1.2.7 1.2.8 1.2.9 All 35 releases
media-cloud-sync / includes / sdk / s3 / Aws / CloudFront / CloudFrontClient.php

CloudFrontClient.php in Media Cloud Sync 1.0.2, at includes/sdk/s3/Aws/CloudFront/CloudFrontClient.php

278 lines 26.6 KB
No matching file
Up and down to move Enter to open Esc to close
Raw Download Zip
1 <?php
2
3 namespace Dudlewebs\WPMCS\s3\Aws\CloudFront;
4
5 use Dudlewebs\WPMCS\s3\Aws\AwsClient;
6 /**
7 * This client is used to interact with the **Amazon CloudFront** service.
8 *
9 * @method \Aws\Result createCloudFrontOriginAccessIdentity(array $args = [])
10 * @method \GuzzleHttp\Promise\Promise createCloudFrontOriginAccessIdentityAsync(array $args = [])
11 * @method \Aws\Result createDistribution(array $args = [])
12 * @method \GuzzleHttp\Promise\Promise createDistributionAsync(array $args = [])
13 * @method \Aws\Result createInvalidation(array $args = [])
14 * @method \GuzzleHttp\Promise\Promise createInvalidationAsync(array $args = [])
15 * @method \Aws\Result createStreamingDistribution(array $args = [])
16 * @method \GuzzleHttp\Promise\Promise createStreamingDistributionAsync(array $args = [])
17 * @method \Aws\Result deleteCloudFrontOriginAccessIdentity(array $args = [])
18 * @method \GuzzleHttp\Promise\Promise deleteCloudFrontOriginAccessIdentityAsync(array $args = [])
19 * @method \Aws\Result deleteDistribution(array $args = [])
20 * @method \GuzzleHttp\Promise\Promise deleteDistributionAsync(array $args = [])
21 * @method \Aws\Result deleteStreamingDistribution(array $args = [])
22 * @method \GuzzleHttp\Promise\Promise deleteStreamingDistributionAsync(array $args = [])
23 * @method \Aws\Result getCloudFrontOriginAccessIdentity(array $args = [])
24 * @method \GuzzleHttp\Promise\Promise getCloudFrontOriginAccessIdentityAsync(array $args = [])
25 * @method \Aws\Result getCloudFrontOriginAccessIdentityConfig(array $args = [])
26 * @method \GuzzleHttp\Promise\Promise getCloudFrontOriginAccessIdentityConfigAsync(array $args = [])
27 * @method \Aws\Result getDistribution(array $args = [])
28 * @method \GuzzleHttp\Promise\Promise getDistributionAsync(array $args = [])
29 * @method \Aws\Result getDistributionConfig(array $args = [])
30 * @method \GuzzleHttp\Promise\Promise getDistributionConfigAsync(array $args = [])
31 * @method \Aws\Result getInvalidation(array $args = [])
32 * @method \GuzzleHttp\Promise\Promise getInvalidationAsync(array $args = [])
33 * @method \Aws\Result getStreamingDistribution(array $args = [])
34 * @method \GuzzleHttp\Promise\Promise getStreamingDistributionAsync(array $args = [])
35 * @method \Aws\Result getStreamingDistributionConfig(array $args = [])
36 * @method \GuzzleHttp\Promise\Promise getStreamingDistributionConfigAsync(array $args = [])
37 * @method \Aws\Result listCloudFrontOriginAccessIdentities(array $args = [])
38 * @method \GuzzleHttp\Promise\Promise listCloudFrontOriginAccessIdentitiesAsync(array $args = [])
39 * @method \Aws\Result listDistributions(array $args = [])
40 * @method \GuzzleHttp\Promise\Promise listDistributionsAsync(array $args = [])
41 * @method \Aws\Result listDistributionsByWebACLId(array $args = [])
42 * @method \GuzzleHttp\Promise\Promise listDistributionsByWebACLIdAsync(array $args = [])
43 * @method \Aws\Result listInvalidations(array $args = [])
44 * @method \GuzzleHttp\Promise\Promise listInvalidationsAsync(array $args = [])
45 * @method \Aws\Result listStreamingDistributions(array $args = [])
46 * @method \GuzzleHttp\Promise\Promise listStreamingDistributionsAsync(array $args = [])
47 * @method \Aws\Result updateCloudFrontOriginAccessIdentity(array $args = [])
48 * @method \GuzzleHttp\Promise\Promise updateCloudFrontOriginAccessIdentityAsync(array $args = [])
49 * @method \Aws\Result updateDistribution(array $args = [])
50 * @method \GuzzleHttp\Promise\Promise updateDistributionAsync(array $args = [])
51 * @method \Aws\Result updateStreamingDistribution(array $args = [])
52 * @method \GuzzleHttp\Promise\Promise updateStreamingDistributionAsync(array $args = [])
53 * @method \Aws\Result createDistributionWithTags(array $args = []) (supported in versions 2016-08-01, 2016-08-20, 2016-09-07, 2016-09-29, 2016-11-25, 2017-03-25, 2017-10-30, 2018-06-18, 2018-11-05, 2019-03-26, 2020-05-31)
54 * @method \GuzzleHttp\Promise\Promise createDistributionWithTagsAsync(array $args = []) (supported in versions 2016-08-01, 2016-08-20, 2016-09-07, 2016-09-29, 2016-11-25, 2017-03-25, 2017-10-30, 2018-06-18, 2018-11-05, 2019-03-26, 2020-05-31)
55 * @method \Aws\Result createStreamingDistributionWithTags(array $args = []) (supported in versions 2016-08-01, 2016-08-20, 2016-09-07, 2016-09-29, 2016-11-25, 2017-03-25, 2017-10-30, 2018-06-18, 2018-11-05, 2019-03-26, 2020-05-31)
56 * @method \GuzzleHttp\Promise\Promise createStreamingDistributionWithTagsAsync(array $args = []) (supported in versions 2016-08-01, 2016-08-20, 2016-09-07, 2016-09-29, 2016-11-25, 2017-03-25, 2017-10-30, 2018-06-18, 2018-11-05, 2019-03-26, 2020-05-31)
57 * @method \Aws\Result listTagsForResource(array $args = []) (supported in versions 2016-08-01, 2016-08-20, 2016-09-07, 2016-09-29, 2016-11-25, 2017-03-25, 2017-10-30, 2018-06-18, 2018-11-05, 2019-03-26, 2020-05-31)
58 * @method \GuzzleHttp\Promise\Promise listTagsForResourceAsync(array $args = []) (supported in versions 2016-08-01, 2016-08-20, 2016-09-07, 2016-09-29, 2016-11-25, 2017-03-25, 2017-10-30, 2018-06-18, 2018-11-05, 2019-03-26, 2020-05-31)
59 * @method \Aws\Result tagResource(array $args = []) (supported in versions 2016-08-01, 2016-08-20, 2016-09-07, 2016-09-29, 2016-11-25, 2017-03-25, 2017-10-30, 2018-06-18, 2018-11-05, 2019-03-26, 2020-05-31)
60 * @method \GuzzleHttp\Promise\Promise tagResourceAsync(array $args = []) (supported in versions 2016-08-01, 2016-08-20, 2016-09-07, 2016-09-29, 2016-11-25, 2017-03-25, 2017-10-30, 2018-06-18, 2018-11-05, 2019-03-26, 2020-05-31)
61 * @method \Aws\Result untagResource(array $args = []) (supported in versions 2016-08-01, 2016-08-20, 2016-09-07, 2016-09-29, 2016-11-25, 2017-03-25, 2017-10-30, 2018-06-18, 2018-11-05, 2019-03-26, 2020-05-31)
62 * @method \GuzzleHttp\Promise\Promise untagResourceAsync(array $args = []) (supported in versions 2016-08-01, 2016-08-20, 2016-09-07, 2016-09-29, 2016-11-25, 2017-03-25, 2017-10-30, 2018-06-18, 2018-11-05, 2019-03-26, 2020-05-31)
63 * @method \Aws\Result deleteServiceLinkedRole(array $args = []) (supported in versions 2017-03-25)
64 * @method \GuzzleHttp\Promise\Promise deleteServiceLinkedRoleAsync(array $args = []) (supported in versions 2017-03-25)
65 * @method \Aws\Result createFieldLevelEncryptionConfig(array $args = []) (supported in versions 2017-10-30, 2018-06-18, 2018-11-05, 2019-03-26, 2020-05-31)
66 * @method \GuzzleHttp\Promise\Promise createFieldLevelEncryptionConfigAsync(array $args = []) (supported in versions 2017-10-30, 2018-06-18, 2018-11-05, 2019-03-26, 2020-05-31)
67 * @method \Aws\Result createFieldLevelEncryptionProfile(array $args = []) (supported in versions 2017-10-30, 2018-06-18, 2018-11-05, 2019-03-26, 2020-05-31)
68 * @method \GuzzleHttp\Promise\Promise createFieldLevelEncryptionProfileAsync(array $args = []) (supported in versions 2017-10-30, 2018-06-18, 2018-11-05, 2019-03-26, 2020-05-31)
69 * @method \Aws\Result createPublicKey(array $args = []) (supported in versions 2017-10-30, 2018-06-18, 2018-11-05, 2019-03-26, 2020-05-31)
70 * @method \GuzzleHttp\Promise\Promise createPublicKeyAsync(array $args = []) (supported in versions 2017-10-30, 2018-06-18, 2018-11-05, 2019-03-26, 2020-05-31)
71 * @method \Aws\Result deleteFieldLevelEncryptionConfig(array $args = []) (supported in versions 2017-10-30, 2018-06-18, 2018-11-05, 2019-03-26, 2020-05-31)
72 * @method \GuzzleHttp\Promise\Promise deleteFieldLevelEncryptionConfigAsync(array $args = []) (supported in versions 2017-10-30, 2018-06-18, 2018-11-05, 2019-03-26, 2020-05-31)
73 * @method \Aws\Result deleteFieldLevelEncryptionProfile(array $args = []) (supported in versions 2017-10-30, 2018-06-18, 2018-11-05, 2019-03-26, 2020-05-31)
74 * @method \GuzzleHttp\Promise\Promise deleteFieldLevelEncryptionProfileAsync(array $args = []) (supported in versions 2017-10-30, 2018-06-18, 2018-11-05, 2019-03-26, 2020-05-31)
75 * @method \Aws\Result deletePublicKey(array $args = []) (supported in versions 2017-10-30, 2018-06-18, 2018-11-05, 2019-03-26, 2020-05-31)
76 * @method \GuzzleHttp\Promise\Promise deletePublicKeyAsync(array $args = []) (supported in versions 2017-10-30, 2018-06-18, 2018-11-05, 2019-03-26, 2020-05-31)
77 * @method \Aws\Result getFieldLevelEncryption(array $args = []) (supported in versions 2017-10-30, 2018-06-18, 2018-11-05, 2019-03-26, 2020-05-31)
78 * @method \GuzzleHttp\Promise\Promise getFieldLevelEncryptionAsync(array $args = []) (supported in versions 2017-10-30, 2018-06-18, 2018-11-05, 2019-03-26, 2020-05-31)
79 * @method \Aws\Result getFieldLevelEncryptionConfig(array $args = []) (supported in versions 2017-10-30, 2018-06-18, 2018-11-05, 2019-03-26, 2020-05-31)
80 * @method \GuzzleHttp\Promise\Promise getFieldLevelEncryptionConfigAsync(array $args = []) (supported in versions 2017-10-30, 2018-06-18, 2018-11-05, 2019-03-26, 2020-05-31)
81 * @method \Aws\Result getFieldLevelEncryptionProfile(array $args = []) (supported in versions 2017-10-30, 2018-06-18, 2018-11-05, 2019-03-26, 2020-05-31)
82 * @method \GuzzleHttp\Promise\Promise getFieldLevelEncryptionProfileAsync(array $args = []) (supported in versions 2017-10-30, 2018-06-18, 2018-11-05, 2019-03-26, 2020-05-31)
83 * @method \Aws\Result getFieldLevelEncryptionProfileConfig(array $args = []) (supported in versions 2017-10-30, 2018-06-18, 2018-11-05, 2019-03-26, 2020-05-31)
84 * @method \GuzzleHttp\Promise\Promise getFieldLevelEncryptionProfileConfigAsync(array $args = []) (supported in versions 2017-10-30, 2018-06-18, 2018-11-05, 2019-03-26, 2020-05-31)
85 * @method \Aws\Result getPublicKey(array $args = []) (supported in versions 2017-10-30, 2018-06-18, 2018-11-05, 2019-03-26, 2020-05-31)
86 * @method \GuzzleHttp\Promise\Promise getPublicKeyAsync(array $args = []) (supported in versions 2017-10-30, 2018-06-18, 2018-11-05, 2019-03-26, 2020-05-31)
87 * @method \Aws\Result getPublicKeyConfig(array $args = []) (supported in versions 2017-10-30, 2018-06-18, 2018-11-05, 2019-03-26, 2020-05-31)
88 * @method \GuzzleHttp\Promise\Promise getPublicKeyConfigAsync(array $args = []) (supported in versions 2017-10-30, 2018-06-18, 2018-11-05, 2019-03-26, 2020-05-31)
89 * @method \Aws\Result listFieldLevelEncryptionConfigs(array $args = []) (supported in versions 2017-10-30, 2018-06-18, 2018-11-05, 2019-03-26, 2020-05-31)
90 * @method \GuzzleHttp\Promise\Promise listFieldLevelEncryptionConfigsAsync(array $args = []) (supported in versions 2017-10-30, 2018-06-18, 2018-11-05, 2019-03-26, 2020-05-31)
91 * @method \Aws\Result listFieldLevelEncryptionProfiles(array $args = []) (supported in versions 2017-10-30, 2018-06-18, 2018-11-05, 2019-03-26, 2020-05-31)
92 * @method \GuzzleHttp\Promise\Promise listFieldLevelEncryptionProfilesAsync(array $args = []) (supported in versions 2017-10-30, 2018-06-18, 2018-11-05, 2019-03-26, 2020-05-31)
93 * @method \Aws\Result listPublicKeys(array $args = []) (supported in versions 2017-10-30, 2018-06-18, 2018-11-05, 2019-03-26, 2020-05-31)
94 * @method \GuzzleHttp\Promise\Promise listPublicKeysAsync(array $args = []) (supported in versions 2017-10-30, 2018-06-18, 2018-11-05, 2019-03-26, 2020-05-31)
95 * @method \Aws\Result updateFieldLevelEncryptionConfig(array $args = []) (supported in versions 2017-10-30, 2018-06-18, 2018-11-05, 2019-03-26, 2020-05-31)
96 * @method \GuzzleHttp\Promise\Promise updateFieldLevelEncryptionConfigAsync(array $args = []) (supported in versions 2017-10-30, 2018-06-18, 2018-11-05, 2019-03-26, 2020-05-31)
97 * @method \Aws\Result updateFieldLevelEncryptionProfile(array $args = []) (supported in versions 2017-10-30, 2018-06-18, 2018-11-05, 2019-03-26, 2020-05-31)
98 * @method \GuzzleHttp\Promise\Promise updateFieldLevelEncryptionProfileAsync(array $args = []) (supported in versions 2017-10-30, 2018-06-18, 2018-11-05, 2019-03-26, 2020-05-31)
99 * @method \Aws\Result updatePublicKey(array $args = []) (supported in versions 2017-10-30, 2018-06-18, 2018-11-05, 2019-03-26, 2020-05-31)
100 * @method \GuzzleHttp\Promise\Promise updatePublicKeyAsync(array $args = []) (supported in versions 2017-10-30, 2018-06-18, 2018-11-05, 2019-03-26, 2020-05-31)
101 * @method \Aws\Result associateAlias(array $args = []) (supported in versions 2020-05-31)
102 * @method \GuzzleHttp\Promise\Promise associateAliasAsync(array $args = []) (supported in versions 2020-05-31)
103 * @method \Aws\Result createCachePolicy(array $args = []) (supported in versions 2020-05-31)
104 * @method \GuzzleHttp\Promise\Promise createCachePolicyAsync(array $args = []) (supported in versions 2020-05-31)
105 * @method \Aws\Result createFunction(array $args = []) (supported in versions 2020-05-31)
106 * @method \GuzzleHttp\Promise\Promise createFunctionAsync(array $args = []) (supported in versions 2020-05-31)
107 * @method \Aws\Result createKeyGroup(array $args = []) (supported in versions 2020-05-31)
108 * @method \GuzzleHttp\Promise\Promise createKeyGroupAsync(array $args = []) (supported in versions 2020-05-31)
109 * @method \Aws\Result createMonitoringSubscription(array $args = []) (supported in versions 2020-05-31)
110 * @method \GuzzleHttp\Promise\Promise createMonitoringSubscriptionAsync(array $args = []) (supported in versions 2020-05-31)
111 * @method \Aws\Result createOriginAccessControl(array $args = []) (supported in versions 2020-05-31)
112 * @method \GuzzleHttp\Promise\Promise createOriginAccessControlAsync(array $args = []) (supported in versions 2020-05-31)
113 * @method \Aws\Result createOriginRequestPolicy(array $args = []) (supported in versions 2020-05-31)
114 * @method \GuzzleHttp\Promise\Promise createOriginRequestPolicyAsync(array $args = []) (supported in versions 2020-05-31)
115 * @method \Aws\Result createRealtimeLogConfig(array $args = []) (supported in versions 2020-05-31)
116 * @method \GuzzleHttp\Promise\Promise createRealtimeLogConfigAsync(array $args = []) (supported in versions 2020-05-31)
117 * @method \Aws\Result createResponseHeadersPolicy(array $args = []) (supported in versions 2020-05-31)
118 * @method \GuzzleHttp\Promise\Promise createResponseHeadersPolicyAsync(array $args = []) (supported in versions 2020-05-31)
119 * @method \Aws\Result deleteCachePolicy(array $args = []) (supported in versions 2020-05-31)
120 * @method \GuzzleHttp\Promise\Promise deleteCachePolicyAsync(array $args = []) (supported in versions 2020-05-31)
121 * @method \Aws\Result deleteFunction(array $args = []) (supported in versions 2020-05-31)
122 * @method \GuzzleHttp\Promise\Promise deleteFunctionAsync(array $args = []) (supported in versions 2020-05-31)
123 * @method \Aws\Result deleteKeyGroup(array $args = []) (supported in versions 2020-05-31)
124 * @method \GuzzleHttp\Promise\Promise deleteKeyGroupAsync(array $args = []) (supported in versions 2020-05-31)
125 * @method \Aws\Result deleteMonitoringSubscription(array $args = []) (supported in versions 2020-05-31)
126 * @method \GuzzleHttp\Promise\Promise deleteMonitoringSubscriptionAsync(array $args = []) (supported in versions 2020-05-31)
127 * @method \Aws\Result deleteOriginAccessControl(array $args = []) (supported in versions 2020-05-31)
128 * @method \GuzzleHttp\Promise\Promise deleteOriginAccessControlAsync(array $args = []) (supported in versions 2020-05-31)
129 * @method \Aws\Result deleteOriginRequestPolicy(array $args = []) (supported in versions 2020-05-31)
130 * @method \GuzzleHttp\Promise\Promise deleteOriginRequestPolicyAsync(array $args = []) (supported in versions 2020-05-31)
131 * @method \Aws\Result deleteRealtimeLogConfig(array $args = []) (supported in versions 2020-05-31)
132 * @method \GuzzleHttp\Promise\Promise deleteRealtimeLogConfigAsync(array $args = []) (supported in versions 2020-05-31)
133 * @method \Aws\Result deleteResponseHeadersPolicy(array $args = []) (supported in versions 2020-05-31)
134 * @method \GuzzleHttp\Promise\Promise deleteResponseHeadersPolicyAsync(array $args = []) (supported in versions 2020-05-31)
135 * @method \Aws\Result describeFunction(array $args = []) (supported in versions 2020-05-31)
136 * @method \GuzzleHttp\Promise\Promise describeFunctionAsync(array $args = []) (supported in versions 2020-05-31)
137 * @method \Aws\Result getCachePolicy(array $args = []) (supported in versions 2020-05-31)
138 * @method \GuzzleHttp\Promise\Promise getCachePolicyAsync(array $args = []) (supported in versions 2020-05-31)
139 * @method \Aws\Result getCachePolicyConfig(array $args = []) (supported in versions 2020-05-31)
140 * @method \GuzzleHttp\Promise\Promise getCachePolicyConfigAsync(array $args = []) (supported in versions 2020-05-31)
141 * @method \Aws\Result getFunction(array $args = []) (supported in versions 2020-05-31)
142 * @method \GuzzleHttp\Promise\Promise getFunctionAsync(array $args = []) (supported in versions 2020-05-31)
143 * @method \Aws\Result getKeyGroup(array $args = []) (supported in versions 2020-05-31)
144 * @method \GuzzleHttp\Promise\Promise getKeyGroupAsync(array $args = []) (supported in versions 2020-05-31)
145 * @method \Aws\Result getKeyGroupConfig(array $args = []) (supported in versions 2020-05-31)
146 * @method \GuzzleHttp\Promise\Promise getKeyGroupConfigAsync(array $args = []) (supported in versions 2020-05-31)
147 * @method \Aws\Result getMonitoringSubscription(array $args = []) (supported in versions 2020-05-31)
148 * @method \GuzzleHttp\Promise\Promise getMonitoringSubscriptionAsync(array $args = []) (supported in versions 2020-05-31)
149 * @method \Aws\Result getOriginAccessControl(array $args = []) (supported in versions 2020-05-31)
150 * @method \GuzzleHttp\Promise\Promise getOriginAccessControlAsync(array $args = []) (supported in versions 2020-05-31)
151 * @method \Aws\Result getOriginAccessControlConfig(array $args = []) (supported in versions 2020-05-31)
152 * @method \GuzzleHttp\Promise\Promise getOriginAccessControlConfigAsync(array $args = []) (supported in versions 2020-05-31)
153 * @method \Aws\Result getOriginRequestPolicy(array $args = []) (supported in versions 2020-05-31)
154 * @method \GuzzleHttp\Promise\Promise getOriginRequestPolicyAsync(array $args = []) (supported in versions 2020-05-31)
155 * @method \Aws\Result getOriginRequestPolicyConfig(array $args = []) (supported in versions 2020-05-31)
156 * @method \GuzzleHttp\Promise\Promise getOriginRequestPolicyConfigAsync(array $args = []) (supported in versions 2020-05-31)
157 * @method \Aws\Result getRealtimeLogConfig(array $args = []) (supported in versions 2020-05-31)
158 * @method \GuzzleHttp\Promise\Promise getRealtimeLogConfigAsync(array $args = []) (supported in versions 2020-05-31)
159 * @method \Aws\Result getResponseHeadersPolicy(array $args = []) (supported in versions 2020-05-31)
160 * @method \GuzzleHttp\Promise\Promise getResponseHeadersPolicyAsync(array $args = []) (supported in versions 2020-05-31)
161 * @method \Aws\Result getResponseHeadersPolicyConfig(array $args = []) (supported in versions 2020-05-31)
162 * @method \GuzzleHttp\Promise\Promise getResponseHeadersPolicyConfigAsync(array $args = []) (supported in versions 2020-05-31)
163 * @method \Aws\Result listCachePolicies(array $args = []) (supported in versions 2020-05-31)
164 * @method \GuzzleHttp\Promise\Promise listCachePoliciesAsync(array $args = []) (supported in versions 2020-05-31)
165 * @method \Aws\Result listConflictingAliases(array $args = []) (supported in versions 2020-05-31)
166 * @method \GuzzleHttp\Promise\Promise listConflictingAliasesAsync(array $args = []) (supported in versions 2020-05-31)
167 * @method \Aws\Result listDistributionsByCachePolicyId(array $args = []) (supported in versions 2020-05-31)
168 * @method \GuzzleHttp\Promise\Promise listDistributionsByCachePolicyIdAsync(array $args = []) (supported in versions 2020-05-31)
169 * @method \Aws\Result listDistributionsByKeyGroup(array $args = []) (supported in versions 2020-05-31)
170 * @method \GuzzleHttp\Promise\Promise listDistributionsByKeyGroupAsync(array $args = []) (supported in versions 2020-05-31)
171 * @method \Aws\Result listDistributionsByOriginRequestPolicyId(array $args = []) (supported in versions 2020-05-31)
172 * @method \GuzzleHttp\Promise\Promise listDistributionsByOriginRequestPolicyIdAsync(array $args = []) (supported in versions 2020-05-31)
173 * @method \Aws\Result listDistributionsByRealtimeLogConfig(array $args = []) (supported in versions 2020-05-31)
174 * @method \GuzzleHttp\Promise\Promise listDistributionsByRealtimeLogConfigAsync(array $args = []) (supported in versions 2020-05-31)
175 * @method \Aws\Result listDistributionsByResponseHeadersPolicyId(array $args = []) (supported in versions 2020-05-31)
176 * @method \GuzzleHttp\Promise\Promise listDistributionsByResponseHeadersPolicyIdAsync(array $args = []) (supported in versions 2020-05-31)
177 * @method \Aws\Result listFunctions(array $args = []) (supported in versions 2020-05-31)
178 * @method \GuzzleHttp\Promise\Promise listFunctionsAsync(array $args = []) (supported in versions 2020-05-31)
179 * @method \Aws\Result listKeyGroups(array $args = []) (supported in versions 2020-05-31)
180 * @method \GuzzleHttp\Promise\Promise listKeyGroupsAsync(array $args = []) (supported in versions 2020-05-31)
181 * @method \Aws\Result listOriginAccessControls(array $args = []) (supported in versions 2020-05-31)
182 * @method \GuzzleHttp\Promise\Promise listOriginAccessControlsAsync(array $args = []) (supported in versions 2020-05-31)
183 * @method \Aws\Result listOriginRequestPolicies(array $args = []) (supported in versions 2020-05-31)
184 * @method \GuzzleHttp\Promise\Promise listOriginRequestPoliciesAsync(array $args = []) (supported in versions 2020-05-31)
185 * @method \Aws\Result listRealtimeLogConfigs(array $args = []) (supported in versions 2020-05-31)
186 * @method \GuzzleHttp\Promise\Promise listRealtimeLogConfigsAsync(array $args = []) (supported in versions 2020-05-31)
187 * @method \Aws\Result listResponseHeadersPolicies(array $args = []) (supported in versions 2020-05-31)
188 * @method \GuzzleHttp\Promise\Promise listResponseHeadersPoliciesAsync(array $args = []) (supported in versions 2020-05-31)
189 * @method \Aws\Result publishFunction(array $args = []) (supported in versions 2020-05-31)
190 * @method \GuzzleHttp\Promise\Promise publishFunctionAsync(array $args = []) (supported in versions 2020-05-31)
191 * @method \Aws\Result testFunction(array $args = []) (supported in versions 2020-05-31)
192 * @method \GuzzleHttp\Promise\Promise testFunctionAsync(array $args = []) (supported in versions 2020-05-31)
193 * @method \Aws\Result updateCachePolicy(array $args = []) (supported in versions 2020-05-31)
194 * @method \GuzzleHttp\Promise\Promise updateCachePolicyAsync(array $args = []) (supported in versions 2020-05-31)
195 * @method \Aws\Result updateFunction(array $args = []) (supported in versions 2020-05-31)
196 * @method \GuzzleHttp\Promise\Promise updateFunctionAsync(array $args = []) (supported in versions 2020-05-31)
197 * @method \Aws\Result updateKeyGroup(array $args = []) (supported in versions 2020-05-31)
198 * @method \GuzzleHttp\Promise\Promise updateKeyGroupAsync(array $args = []) (supported in versions 2020-05-31)
199 * @method \Aws\Result updateOriginAccessControl(array $args = []) (supported in versions 2020-05-31)
200 * @method \GuzzleHttp\Promise\Promise updateOriginAccessControlAsync(array $args = []) (supported in versions 2020-05-31)
201 * @method \Aws\Result updateOriginRequestPolicy(array $args = []) (supported in versions 2020-05-31)
202 * @method \GuzzleHttp\Promise\Promise updateOriginRequestPolicyAsync(array $args = []) (supported in versions 2020-05-31)
203 * @method \Aws\Result updateRealtimeLogConfig(array $args = []) (supported in versions 2020-05-31)
204 * @method \GuzzleHttp\Promise\Promise updateRealtimeLogConfigAsync(array $args = []) (supported in versions 2020-05-31)
205 * @method \Aws\Result updateResponseHeadersPolicy(array $args = []) (supported in versions 2020-05-31)
206 * @method \GuzzleHttp\Promise\Promise updateResponseHeadersPolicyAsync(array $args = []) (supported in versions 2020-05-31)
207 */
208 class CloudFrontClient extends AwsClient
209 {
210 /**
211 * Create a signed Amazon CloudFront URL.
212 *
213 * This method accepts an array of configuration options:
214 *
215 * - url: (string) URL of the resource being signed (can include query
216 * string and wildcards). For example: rtmp://s5c39gqb8ow64r.cloudfront.net/videos/mp3_name.mp3
217 * http://d111111abcdef8.cloudfront.net/images/horizon.jpg?size=large&license=yes
218 * - policy: (string) JSON policy. Use this option when creating a signed
219 * URL for a custom policy.
220 * - expires: (int) UTC Unix timestamp used when signing with a canned
221 * policy. Not required when passing a custom 'policy' option.
222 * - key_pair_id: (string) The ID of the key pair used to sign CloudFront
223 * URLs for private distributions.
224 * - private_key: (string) The filepath ot the private key used to sign
225 * CloudFront URLs for private distributions.
226 *
227 * @param array $options Array of configuration options used when signing
228 *
229 * @return string Signed URL with authentication parameters
230 * @throws \InvalidArgumentException if url, key_pair_id, or private_key
231 * were not specified.
232 * @link http://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/WorkingWithStreamingDistributions.html
233 */
234 public function getSignedUrl(array $options)
235 {
236 foreach (['url', 'key_pair_id', 'private_key'] as $required) {
237 if (!isset($options[$required])) {
238 throw new \InvalidArgumentException("{$required} is required");
239 }
240 }
241 $urlSigner = new UrlSigner($options['key_pair_id'], $options['private_key']);
242 return $urlSigner->getSignedUrl($options['url'], isset($options['expires']) ? $options['expires'] : null, isset($options['policy']) ? $options['policy'] : null);
243 }
244 /**
245 * Create a signed Amazon CloudFront cookie.
246 *
247 * This method accepts an array of configuration options:
248 *
249 * - url: (string) URL of the resource being signed (can include query
250 * string and wildcards). For example: http://d111111abcdef8.cloudfront.net/images/horizon.jpg?size=large&license=yes
251 * - policy: (string) JSON policy. Use this option when creating a signed
252 * URL for a custom policy.
253 * - expires: (int) UTC Unix timestamp used when signing with a canned
254 * policy. Not required when passing a custom 'policy' option.
255 * - key_pair_id: (string) The ID of the key pair used to sign CloudFront
256 * URLs for private distributions.
257 * - private_key: (string) The filepath ot the private key used to sign
258 * CloudFront URLs for private distributions.
259 *
260 * @param array $options Array of configuration options used when signing
261 *
262 * @return array Key => value pairs of signed cookies to set
263 * @throws \InvalidArgumentException if url, key_pair_id, or private_key
264 * were not specified.
265 * @link http://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/WorkingWithStreamingDistributions.html
266 */
267 public function getSignedCookie(array $options)
268 {
269 foreach (['key_pair_id', 'private_key'] as $required) {
270 if (!isset($options[$required])) {
271 throw new \InvalidArgumentException("{$required} is required");
272 }
273 }
274 $cookieSigner = new CookieSigner($options['key_pair_id'], $options['private_key']);
275 return $cookieSigner->getSignedCookie(isset($options['url']) ? $options['url'] : null, isset($options['expires']) ? $options['expires'] : null, isset($options['policy']) ? $options['policy'] : null);
276 }
277 }
278