PluginProbe
VikBooking Hotel Booking Engine & PMS / trunk
VikBooking Hotel Booking Engine & PMS vtrunk
1.8.15 1.8.14 1.8.13 1.8.12 1.8.11 1.8.10 1.8.9 1.8.6 1.8.7 1.8.8 trunk 1.6.0 1.6.1 1.6.2 1.6.3 1.6.4 1.6.5 1.6.6 1.6.7 1.6.8 1.6.9 1.7.0 1.7.1 1.7.2 1.7.3 All 36 releases
vikbooking / libraries / adapter / cipher / crypto.php

crypto.php in VikBooking Hotel Booking Engine & PMS trunk, at libraries/adapter/cipher/crypto.php

67 lines 1.7 KB
No matching file
Up and down to move Enter to open Esc to close
Raw Download Zip
1 <?php
2 /**
3 * @package VikWP - Libraries
4 * @subpackage adapter.html
5 * @author E4J s.r.l.
6 * @copyright Copyright (C) 2023 E4J s.r.l. All Rights Reserved.
7 * @license http://www.gnu.org/licenses/gpl-2.0.html GNU/GPL
8 * @link https://vikwp.com
9 */
10
11 // No direct access
12 defined('ABSPATH') or die('No script kiddies please!');
13
14 JLoader::import('adapter.cipher.key');
15
16 /**
17 * Crypt cipher for encryption, decryption and key generation via the php-encryption library.
18 *
19 * @since 10.1.20
20 */
21 class JCryptCipherCrypto
22 {
23 /**
24 * Method to decrypt a data string.
25 *
26 * @param string $data The encrypted string to decrypt.
27 * @param JCryptKey $key The key object to use for decryption.
28 *
29 * @return string The decrypted data string.
30 *
31 * @throws RuntimeException
32 */
33 public function decrypt($data, JCryptKey $key)
34 {
35 throw new RuntimeException(sprintf('Missing %s implementation', __METHOD__), 501);
36 }
37
38 /**
39 * Method to encrypt a data string.
40 *
41 * @param string $data The data string to encrypt.
42 * @param JCryptKey $key The key object to use for encryption.
43 *
44 * @return string The encrypted data string.
45 *
46 * @throws RuntimeException
47 */
48 public function encrypt($data, JCryptKey $key)
49 {
50 throw new RuntimeException(sprintf('Missing %s implementation', __METHOD__), 501);
51 }
52
53 /**
54 * Method to generate a new encryption key object.
55 *
56 * @param array $options Key generation options.
57 *
58 * @return JCryptKey
59 *
60 * @throws RuntimeException
61 */
62 public function generateKey(array $options = array())
63 {
64 throw new RuntimeException(sprintf('Missing %s implementation', __METHOD__), 501);
65 }
66 }
67