Debian Codegraph @

lib/3rdParty/composer/aws/aws-sdk-php/src/Crypto/MaterialsProviderInterfaceV3.php

raw symbols SCIP
1 <?php
2 namespace Aws\Crypto;
3
4 interface MaterialsProviderInterfaceV3
5 {
6 /**
7 * Returns if the requested size is supported by AES.
8 *
9 * @param int $keySize Size of the requested key in bits.
10 *
11 * @return bool
12 */
13 public static function isSupportedKeySize(int $keySize): bool;
14
15 /**
16 * Returns the wrap algorithm name for this Provider.
17 *
18 * @return string
19 */
20 public function getWrapAlgorithmName(): string;
21
22 /**
23 * Takes an encrypted content encryption key (CEK) and material description
24 * for use decrypting the key according to the Provider's specifications.
25 *
26 * @param string $encryptedCek Encrypted key to be decrypted by the Provider
27 * for use decrypting other data.
28 * @param array $materialDescription Material Description for use in
29 * decrypting the CEK.
30 * @param AlgorithmSuite $algorithmSuite AlgorithmSuite for use in decrypting the CEK.
31 *
32 * @return string
33 */
34 public function decryptCek(
35 string $encryptedCek,
36 array $materialDescription,
37 array $options
38 ): string;
39
40 /**
41 * @param string $keySize Length of a cipher key in bits for generating a
42 * random content encryption key (CEK).
43 * @param array $context Context map needed for key encryption
44 * @param array $options Additional options to be used in CEK generation
45 *
46 * @return array
47 */
48 public function generateCek(
49 string $keySize,
50 array $context,
51 array $options
52 ): array;
53
54 /**
55 * @param string $openSslName Cipher OpenSSL name to use for generating
56 * an initialization vector.
57 *
58 * @return string
59 */
60 public function generateIv(string $openSslName): string;
61 }