CertificateIssuanceConfig.php 6.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245
  1. <?php
  2. /*
  3. * Copyright 2014 Google Inc.
  4. *
  5. * Licensed under the Apache License, Version 2.0 (the "License"); you may not
  6. * use this file except in compliance with the License. You may obtain a copy of
  7. * the License at
  8. *
  9. * http://www.apache.org/licenses/LICENSE-2.0
  10. *
  11. * Unless required by applicable law or agreed to in writing, software
  12. * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
  13. * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
  14. * License for the specific language governing permissions and limitations under
  15. * the License.
  16. */
  17. namespace Google\Service\CertificateManager;
  18. class CertificateIssuanceConfig extends \Google\Model
  19. {
  20. /**
  21. * Unspecified key algorithm.
  22. */
  23. public const KEY_ALGORITHM_KEY_ALGORITHM_UNSPECIFIED = 'KEY_ALGORITHM_UNSPECIFIED';
  24. /**
  25. * Specifies RSA with a 2048-bit modulus.
  26. */
  27. public const KEY_ALGORITHM_RSA_2048 = 'RSA_2048';
  28. /**
  29. * Specifies ECDSA with curve P256.
  30. */
  31. public const KEY_ALGORITHM_ECDSA_P256 = 'ECDSA_P256';
  32. protected $certificateAuthorityConfigType = CertificateAuthorityConfig::class;
  33. protected $certificateAuthorityConfigDataType = '';
  34. /**
  35. * Output only. The creation timestamp of a CertificateIssuanceConfig.
  36. *
  37. * @var string
  38. */
  39. public $createTime;
  40. /**
  41. * Optional. One or more paragraphs of text description of a
  42. * CertificateIssuanceConfig.
  43. *
  44. * @var string
  45. */
  46. public $description;
  47. /**
  48. * Required. The key algorithm to use when generating the private key.
  49. *
  50. * @var string
  51. */
  52. public $keyAlgorithm;
  53. /**
  54. * Optional. Set of labels associated with a CertificateIssuanceConfig.
  55. *
  56. * @var string[]
  57. */
  58. public $labels;
  59. /**
  60. * Required. Workload certificate lifetime requested.
  61. *
  62. * @var string
  63. */
  64. public $lifetime;
  65. /**
  66. * Identifier. A user-defined name of the certificate issuance config.
  67. * CertificateIssuanceConfig names must be unique globally and match pattern
  68. * `projects/locations/certificateIssuanceConfigs`.
  69. *
  70. * @var string
  71. */
  72. public $name;
  73. /**
  74. * Required. Specifies the percentage of elapsed time of the certificate
  75. * lifetime to wait before renewing the certificate. Must be a number between
  76. * 1-99, inclusive.
  77. *
  78. * @var int
  79. */
  80. public $rotationWindowPercentage;
  81. /**
  82. * Output only. The last update timestamp of a CertificateIssuanceConfig.
  83. *
  84. * @var string
  85. */
  86. public $updateTime;
  87. /**
  88. * Required. The CA that issues the workload certificate. It includes the CA
  89. * address, type, authentication to CA service, etc.
  90. *
  91. * @param CertificateAuthorityConfig $certificateAuthorityConfig
  92. */
  93. public function setCertificateAuthorityConfig(CertificateAuthorityConfig $certificateAuthorityConfig)
  94. {
  95. $this->certificateAuthorityConfig = $certificateAuthorityConfig;
  96. }
  97. /**
  98. * @return CertificateAuthorityConfig
  99. */
  100. public function getCertificateAuthorityConfig()
  101. {
  102. return $this->certificateAuthorityConfig;
  103. }
  104. /**
  105. * Output only. The creation timestamp of a CertificateIssuanceConfig.
  106. *
  107. * @param string $createTime
  108. */
  109. public function setCreateTime($createTime)
  110. {
  111. $this->createTime = $createTime;
  112. }
  113. /**
  114. * @return string
  115. */
  116. public function getCreateTime()
  117. {
  118. return $this->createTime;
  119. }
  120. /**
  121. * Optional. One or more paragraphs of text description of a
  122. * CertificateIssuanceConfig.
  123. *
  124. * @param string $description
  125. */
  126. public function setDescription($description)
  127. {
  128. $this->description = $description;
  129. }
  130. /**
  131. * @return string
  132. */
  133. public function getDescription()
  134. {
  135. return $this->description;
  136. }
  137. /**
  138. * Required. The key algorithm to use when generating the private key.
  139. *
  140. * Accepted values: KEY_ALGORITHM_UNSPECIFIED, RSA_2048, ECDSA_P256
  141. *
  142. * @param self::KEY_ALGORITHM_* $keyAlgorithm
  143. */
  144. public function setKeyAlgorithm($keyAlgorithm)
  145. {
  146. $this->keyAlgorithm = $keyAlgorithm;
  147. }
  148. /**
  149. * @return self::KEY_ALGORITHM_*
  150. */
  151. public function getKeyAlgorithm()
  152. {
  153. return $this->keyAlgorithm;
  154. }
  155. /**
  156. * Optional. Set of labels associated with a CertificateIssuanceConfig.
  157. *
  158. * @param string[] $labels
  159. */
  160. public function setLabels($labels)
  161. {
  162. $this->labels = $labels;
  163. }
  164. /**
  165. * @return string[]
  166. */
  167. public function getLabels()
  168. {
  169. return $this->labels;
  170. }
  171. /**
  172. * Required. Workload certificate lifetime requested.
  173. *
  174. * @param string $lifetime
  175. */
  176. public function setLifetime($lifetime)
  177. {
  178. $this->lifetime = $lifetime;
  179. }
  180. /**
  181. * @return string
  182. */
  183. public function getLifetime()
  184. {
  185. return $this->lifetime;
  186. }
  187. /**
  188. * Identifier. A user-defined name of the certificate issuance config.
  189. * CertificateIssuanceConfig names must be unique globally and match pattern
  190. * `projects/locations/certificateIssuanceConfigs`.
  191. *
  192. * @param string $name
  193. */
  194. public function setName($name)
  195. {
  196. $this->name = $name;
  197. }
  198. /**
  199. * @return string
  200. */
  201. public function getName()
  202. {
  203. return $this->name;
  204. }
  205. /**
  206. * Required. Specifies the percentage of elapsed time of the certificate
  207. * lifetime to wait before renewing the certificate. Must be a number between
  208. * 1-99, inclusive.
  209. *
  210. * @param int $rotationWindowPercentage
  211. */
  212. public function setRotationWindowPercentage($rotationWindowPercentage)
  213. {
  214. $this->rotationWindowPercentage = $rotationWindowPercentage;
  215. }
  216. /**
  217. * @return int
  218. */
  219. public function getRotationWindowPercentage()
  220. {
  221. return $this->rotationWindowPercentage;
  222. }
  223. /**
  224. * Output only. The last update timestamp of a CertificateIssuanceConfig.
  225. *
  226. * @param string $updateTime
  227. */
  228. public function setUpdateTime($updateTime)
  229. {
  230. $this->updateTime = $updateTime;
  231. }
  232. /**
  233. * @return string
  234. */
  235. public function getUpdateTime()
  236. {
  237. return $this->updateTime;
  238. }
  239. }
  240. // Adding a class alias for backwards compatibility with the previous class name.
  241. class_alias(CertificateIssuanceConfig::class, 'Google_Service_CertificateManager_CertificateIssuanceConfig');