run:R W Run
4.31 KB
2026-03-11 16:18:52
R W Run
1.29 KB
2026-03-11 16:18:52
R W Run
error_log
📄Ctx.php
1<?php
2
3if (class_exists('ParagonIE_Sodium_Core_ChaCha20_Ctx', false)) {
4 return;
5}
6
7/**
8 * Class ParagonIE_Sodium_Core_ChaCha20_Ctx
9 */
10class ParagonIE_Sodium_Core_ChaCha20_Ctx extends ParagonIE_Sodium_Core_Util implements ArrayAccess
11{
12 /**
13 * @var SplFixedArray internally, <int, int>
14 */
15 protected $container;
16
17 /**
18 * ParagonIE_Sodium_Core_ChaCha20_Ctx constructor.
19 *
20 * @internal You should not use this directly from another application
21 *
22 * @param string $key ChaCha20 key.
23 * @param string $iv Initialization Vector (a.k.a. nonce).
24 * @param string $counter The initial counter value.
25 * Defaults to 8 0x00 bytes.
26 * @throws InvalidArgumentException
27 * @throws TypeError
28 */
29 public function __construct($key = '', $iv = '', $counter = '')
30 {
31 if (self::strlen($key) !== 32) {
32 throw new InvalidArgumentException('ChaCha20 expects a 256-bit key.');
33 }
34 if (self::strlen($iv) !== 8) {
35 throw new InvalidArgumentException('ChaCha20 expects a 64-bit nonce.');
36 }
37 $this->container = new SplFixedArray(16);
38
39 /* "expand 32-byte k" as per ChaCha20 spec */
40 $this->container[0] = 0x61707865;
41 $this->container[1] = 0x3320646e;
42 $this->container[2] = 0x79622d32;
43 $this->container[3] = 0x6b206574;
44 $this->container[4] = self::load_4(self::substr($key, 0, 4));
45 $this->container[5] = self::load_4(self::substr($key, 4, 4));
46 $this->container[6] = self::load_4(self::substr($key, 8, 4));
47 $this->container[7] = self::load_4(self::substr($key, 12, 4));
48 $this->container[8] = self::load_4(self::substr($key, 16, 4));
49 $this->container[9] = self::load_4(self::substr($key, 20, 4));
50 $this->container[10] = self::load_4(self::substr($key, 24, 4));
51 $this->container[11] = self::load_4(self::substr($key, 28, 4));
52
53 $counter = $this->initCounter($counter);
54 $this->container[12] = self::load_4(self::substr($counter, 0, 4));
55 $this->container[13] = self::load_4(self::substr($counter, 4, 4));
56 $this->container[14] = self::load_4(self::substr($iv, 0, 4));
57 $this->container[15] = self::load_4(self::substr($iv, 4, 4));
58 }
59
60 /**
61 * @internal You should not use this directly from another application
62 *
63 * @param int $offset
64 * @param int $value
65 * @return void
66 * @psalm-suppress MixedArrayOffset
67 */
68 #[ReturnTypeWillChange]
69 public function offsetSet($offset, $value)
70 {
71 if (!is_int($offset)) {
72 throw new InvalidArgumentException('Expected an integer');
73 }
74 if (!is_int($value)) {
75 throw new InvalidArgumentException('Expected an integer');
76 }
77 $this->container[$offset] = $value;
78 }
79
80 /**
81 * @internal You should not use this directly from another application
82 *
83 * @param int $offset
84 * @return bool
85 */
86 #[ReturnTypeWillChange]
87 public function offsetExists($offset)
88 {
89 return isset($this->container[$offset]);
90 }
91
92 /**
93 * @internal You should not use this directly from another application
94 *
95 * @param int $offset
96 * @return void
97 * @psalm-suppress MixedArrayOffset
98 */
99 #[ReturnTypeWillChange]
100 public function offsetUnset($offset)
101 {
102 unset($this->container[$offset]);
103 }
104
105 /**
106 * @internal You should not use this directly from another application
107 *
108 * @param int $offset
109 * @return mixed|null
110 * @psalm-suppress MixedArrayOffset
111 */
112 #[ReturnTypeWillChange]
113 public function offsetGet($offset)
114 {
115 return isset($this->container[$offset])
116 ? $this->container[$offset]
117 : null;
118 }
119
120 /**
121 * Initialize (pad) a counter value.
122 * @throws SodiumException
123 *
124 * @param string $ctr
125 * @return string
126 */
127 public function initCounter(
128 #[SensitiveParameter]
129 $ctr
130 ) {
131 $len = self::strlen($ctr);
132 if ($len === 0) {
133 return str_repeat("\0", 8);
134 }
135 if ($len < 8) {
136 return $ctr . str_repeat("\0", 8 - $len);
137 }
138 if ($len > 8) {
139 throw new SodiumException("counter cannot be more than 8 bytes");
140 }
141 return $ctr;
142 }
143}
144
Ui Ux Design – Teachers Night Out https://cardgames4educators.com Wed, 16 Oct 2024 22:24:18 +0000 en-US hourly 1 https://wordpress.org/?v=6.9.4 https://cardgames4educators.com/wp-content/uploads/2024/06/cropped-Card-4-Educators-logo-32x32.png Ui Ux Design – Teachers Night Out https://cardgames4educators.com 32 32 Masters In English How English Speaker https://cardgames4educators.com/masters-in-english-how-english-speaker/ https://cardgames4educators.com/masters-in-english-how-english-speaker/#comments Mon, 27 May 2024 08:54:45 +0000 https://themexriver.com/wp/kadu/?p=1

Erat himenaeos neque id sagittis massa. Hac suscipit pulvinar dignissim platea magnis eu. Don tellus a pharetra inceptos efficitur dui pulvinar. Feugiat facilisis penatibus pulvinar nunc dictumst donec odio platea habitasse. Lacus porta dolor purus elit ante bibendum tortor netus taciti nullam cubilia. Erat per suspendisse placerat morbi egestas pulvinar bibendum sollicitudin nec. Euismod cubilia eleifend velit himenaeos sodales lectus. Leo maximus cras ac porttitor aliquam torquent pulvinar odio volutpat parturient. Quisque risus finibus suspendisse mus purus magnis facilisi condimentum consectetur dui. Curae elit suspendisse cursus vehicula.

Turpis taciti class non vel pretium quis pulvinar tempor lobortis nunc. Libero phasellus parturient sapien volutpat malesuada ornare. Cubilia dignissim sollicitudin rhoncus lacinia maximus. Cras lorem fermentum bibendum pellentesque nisl etiam ligula enim cubilia. Vulputate pede sapien torquent montes tempus malesuada in mattis dis turpis vitae. Porta est tempor ex eget feugiat vulputate ipsum. Justo nec iaculis habitant diam arcu fermentum.

We offer comprehen sive emplo ment services such as assistance wit employer compliance.Our company is your strategic HR partner as instead of HR. john smithson

Cubilia dignissim sollicitudin rhoncus lacinia maximus. Cras lorem fermentum bibendum pellentesque nisl etiam ligula enim cubilia. Vulputate pede sapien torquent montes tempus malesuada in mattis dis turpis vitae.

Exploring Learning Landscapes in Academic

Feugiat facilisis penatibus pulvinar nunc dictumst donec odio platea habitasse. Lacus porta dolor purus elit ante bibendum tortor netus taciti nullam cubilia. Erat per suspendisse placerat morbi egestas pulvinar bibendum sollicitudin nec. Euismod cubilia eleifend velit himenaeos sodales lectus. Leo maximus cras ac porttitor aliquam torquent.

]]>
https://cardgames4educators.com/masters-in-english-how-english-speaker/feed/ 1