fix: 修复配额说明重复和undefined问题
- 在editStorageForm中初始化oss_storage_quota_value和oss_quota_unit - 删除重复的旧配额说明块,保留新的当前配额设置显示 Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
This commit is contained in:
106
backend/node_modules/@aws-crypto/sha256-js/CHANGELOG.md
generated
vendored
Normal file
106
backend/node_modules/@aws-crypto/sha256-js/CHANGELOG.md
generated
vendored
Normal file
@@ -0,0 +1,106 @@
|
||||
# Change Log
|
||||
|
||||
All notable changes to this project will be documented in this file.
|
||||
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
|
||||
|
||||
# [5.2.0](https://github.com/aws/aws-sdk-js-crypto-helpers/compare/v5.1.0...v5.2.0) (2023-10-16)
|
||||
|
||||
### Features
|
||||
|
||||
- support ESM artifacts in all packages ([#752](https://github.com/aws/aws-sdk-js-crypto-helpers/issues/752)) ([e930ffb](https://github.com/aws/aws-sdk-js-crypto-helpers/commit/e930ffba5cfef66dd242049e7d514ced232c1e3b))
|
||||
|
||||
# [5.1.0](https://github.com/aws/aws-sdk-js-crypto-helpers/compare/v5.0.0...v5.1.0) (2023-09-22)
|
||||
|
||||
### Bug Fixes
|
||||
|
||||
- Update tsc to 2.x ([#735](https://github.com/aws/aws-sdk-js-crypto-helpers/issues/735)) ([782e0de](https://github.com/aws/aws-sdk-js-crypto-helpers/commit/782e0de9f5fef41f694130580a69d940894b6b8c))
|
||||
|
||||
# [5.0.0](https://github.com/aws/aws-sdk-js-crypto-helpers/compare/v4.0.1...v5.0.0) (2023-07-13)
|
||||
|
||||
**Note:** Version bump only for package @aws-crypto/sha256-js
|
||||
|
||||
# [4.0.0](https://github.com/aws/aws-sdk-js-crypto-helpers/compare/v3.0.0...v4.0.0) (2023-02-20)
|
||||
|
||||
**Note:** Version bump only for package @aws-crypto/sha256-js
|
||||
|
||||
# [3.0.0](https://github.com/aws/aws-sdk-js-crypto-helpers/compare/v2.0.2...v3.0.0) (2023-01-12)
|
||||
|
||||
### Bug Fixes
|
||||
|
||||
- **docs:** sha256 packages, clarify hmac support ([#455](https://github.com/aws/aws-sdk-js-crypto-helpers/issues/455)) ([1be5043](https://github.com/aws/aws-sdk-js-crypto-helpers/commit/1be5043325991f3f5ccb52a8dd928f004b4d442e))
|
||||
|
||||
- feat!: replace Hash implementations with Checksum interface (#492) ([da43dc0](https://github.com/aws/aws-sdk-js-crypto-helpers/commit/da43dc0fdf669d9ebb5bfb1b1f7c79e46c4aaae1)), closes [#492](https://github.com/aws/aws-sdk-js-crypto-helpers/issues/492)
|
||||
|
||||
### BREAKING CHANGES
|
||||
|
||||
- All classes that implemented `Hash` now implement `Checksum`.
|
||||
|
||||
## [2.0.2](https://github.com/aws/aws-sdk-js-crypto-helpers/compare/v2.0.1...v2.0.2) (2022-09-07)
|
||||
|
||||
### Bug Fixes
|
||||
|
||||
- **#337:** update @aws-sdk/types ([#373](https://github.com/aws/aws-sdk-js-crypto-helpers/issues/373)) ([b26a811](https://github.com/aws/aws-sdk-js-crypto-helpers/commit/b26a811a392f5209c7ec7e57251500d4d78f97ff)), closes [#337](https://github.com/aws/aws-sdk-js-crypto-helpers/issues/337)
|
||||
|
||||
## [2.0.1](https://github.com/aws/aws-sdk-js-crypto-helpers/compare/v2.0.0...v2.0.1) (2021-12-09)
|
||||
|
||||
**Note:** Version bump only for package @aws-crypto/sha256-js
|
||||
|
||||
# [2.0.0](https://github.com/aws/aws-sdk-js-crypto-helpers/compare/v1.2.2...v2.0.0) (2021-10-25)
|
||||
|
||||
**Note:** Version bump only for package @aws-crypto/sha256-js
|
||||
|
||||
## [1.2.2](https://github.com/aws/aws-sdk-js-crypto-helpers/compare/v1.2.1...v1.2.2) (2021-10-12)
|
||||
|
||||
**Note:** Version bump only for package @aws-crypto/sha256-js
|
||||
|
||||
## [1.2.1](https://github.com/aws/aws-sdk-js-crypto-helpers/compare/v1.2.0...v1.2.1) (2021-09-17)
|
||||
|
||||
**Note:** Version bump only for package @aws-crypto/sha256-js
|
||||
|
||||
# [1.2.0](https://github.com/aws/aws-sdk-js-crypto-helpers/compare/v1.1.1...v1.2.0) (2021-09-17)
|
||||
|
||||
### Features
|
||||
|
||||
- add @aws-crypto/util ([8f489cb](https://github.com/aws/aws-sdk-js-crypto-helpers/commit/8f489cbe4c0e134f826bac66f1bf5172597048b9))
|
||||
|
||||
# [1.1.0](https://github.com/aws/aws-sdk-js-crypto-helpers/compare/@aws-crypto/sha256-js@1.0.0...@aws-crypto/sha256-js@1.1.0) (2021-01-13)
|
||||
|
||||
### Bug Fixes
|
||||
|
||||
- remove package lock ([6002a5a](https://github.com/aws/aws-sdk-js-crypto-helpers/commit/6002a5ab9218dc8798c19dc205d3eebd3bec5b43))
|
||||
- **aws-crypto:** export explicit dependencies on [@aws-types](https://github.com/aws-types) ([6a1873a](https://github.com/aws/aws-sdk-js-crypto-helpers/commit/6a1873a4dcc2aaa4a1338595703cfa7099f17b8c))
|
||||
- **deps-dev:** move @aws-sdk/types to devDependencies ([#188](https://github.com/aws/aws-sdk-js-crypto-helpers/issues/188)) ([08efdf4](https://github.com/aws/aws-sdk-js-crypto-helpers/commit/08efdf46dcc612d88c441e29945d787f253ee77d))
|
||||
|
||||
# [1.0.0](https://github.com/aws/aws-sdk-js-crypto-helpers/compare/@aws-crypto/sha256-js@1.0.0-alpha.0...@aws-crypto/sha256-js@1.0.0) (2020-10-22)
|
||||
|
||||
**Note:** Version bump only for package @aws-crypto/sha256-js
|
||||
|
||||
# [1.0.0-alpha.0](https://github.com/aws/aws-sdk-js-crypto-helpers/compare/@aws-crypto/sha256-js@0.1.0-preview.4...@aws-crypto/sha256-js@1.0.0-alpha.0) (2020-02-07)
|
||||
|
||||
**Note:** Version bump only for package @aws-crypto/sha256-js
|
||||
|
||||
# [0.1.0-preview.4](https://github.com/aws/aws-sdk-js-crypto-helpers/compare/@aws-crypto/sha256-js@0.1.0-preview.2...@aws-crypto/sha256-js@0.1.0-preview.4) (2020-01-16)
|
||||
|
||||
### Bug Fixes
|
||||
|
||||
- Changed package.json files to point to the right Git repo ([#9](https://github.com/aws/aws-sdk-js-crypto-helpers/issues/9)) ([028245d](https://github.com/aws/aws-sdk-js-crypto-helpers/commit/028245d72e642ca98d82226afb300eb154503c4a)), closes [#8](https://github.com/aws/aws-sdk-js-crypto-helpers/issues/8)
|
||||
- es2015.iterable required ([#10](https://github.com/aws/aws-sdk-js-crypto-helpers/issues/10)) ([6e08d83](https://github.com/aws/aws-sdk-js-crypto-helpers/commit/6e08d83c33667ad8cbeeaaa7cedf1bbe05f79ed8))
|
||||
- lerna version maintains package-lock ([#14](https://github.com/aws/aws-sdk-js-crypto-helpers/issues/14)) ([2ef29e1](https://github.com/aws/aws-sdk-js-crypto-helpers/commit/2ef29e13779703a5c9b32e93d18918fcb33b7272)), closes [#13](https://github.com/aws/aws-sdk-js-crypto-helpers/issues/13)
|
||||
|
||||
# [0.1.0-preview.3](https://github.com/aws/aws-sdk-js-crypto-helpers/compare/@aws-crypto/sha256-js@0.1.0-preview.2...@aws-crypto/sha256-js@0.1.0-preview.3) (2019-11-15)
|
||||
|
||||
### Bug Fixes
|
||||
|
||||
- Changed package.json files to point to the right Git repo ([#9](https://github.com/aws/aws-sdk-js-crypto-helpers/issues/9)) ([028245d](https://github.com/aws/aws-sdk-js-crypto-helpers/commit/028245d72e642ca98d82226afb300eb154503c4a)), closes [#8](https://github.com/aws/aws-sdk-js-crypto-helpers/issues/8)
|
||||
- es2015.iterable required ([#10](https://github.com/aws/aws-sdk-js-crypto-helpers/issues/10)) ([6e08d83](https://github.com/aws/aws-sdk-js-crypto-helpers/commit/6e08d83c33667ad8cbeeaaa7cedf1bbe05f79ed8))
|
||||
- lerna version maintains package-lock ([#14](https://github.com/aws/aws-sdk-js-crypto-helpers/issues/14)) ([2ef29e1](https://github.com/aws/aws-sdk-js-crypto-helpers/commit/2ef29e13779703a5c9b32e93d18918fcb33b7272)), closes [#13](https://github.com/aws/aws-sdk-js-crypto-helpers/issues/13)
|
||||
|
||||
# [0.1.0-preview.2](https://github.com/aws/aws-javascript-crypto-helpers/compare/@aws-crypto/sha256-js@0.1.0-preview.1...@aws-crypto/sha256-js@0.1.0-preview.2) (2019-10-30)
|
||||
|
||||
### Bug Fixes
|
||||
|
||||
- remove /src/ from .npmignore (for sourcemaps) ([#5](https://github.com/aws/aws-javascript-crypto-helpers/issues/5)) ([ec52056](https://github.com/aws/aws-javascript-crypto-helpers/commit/ec52056))
|
||||
|
||||
### Features
|
||||
|
||||
- **sha256-js:** expose synchronous digest ([#7](https://github.com/aws/aws-javascript-crypto-helpers/issues/7)) ([9edaef7](https://github.com/aws/aws-javascript-crypto-helpers/commit/9edaef7)), closes [#6](https://github.com/aws/aws-javascript-crypto-helpers/issues/6)
|
||||
201
backend/node_modules/@aws-crypto/sha256-js/LICENSE
generated
vendored
Normal file
201
backend/node_modules/@aws-crypto/sha256-js/LICENSE
generated
vendored
Normal file
@@ -0,0 +1,201 @@
|
||||
Apache License
|
||||
Version 2.0, January 2004
|
||||
http://www.apache.org/licenses/
|
||||
|
||||
TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
|
||||
|
||||
1. Definitions.
|
||||
|
||||
"License" shall mean the terms and conditions for use, reproduction,
|
||||
and distribution as defined by Sections 1 through 9 of this document.
|
||||
|
||||
"Licensor" shall mean the copyright owner or entity authorized by
|
||||
the copyright owner that is granting the License.
|
||||
|
||||
"Legal Entity" shall mean the union of the acting entity and all
|
||||
other entities that control, are controlled by, or are under common
|
||||
control with that entity. For the purposes of this definition,
|
||||
"control" means (i) the power, direct or indirect, to cause the
|
||||
direction or management of such entity, whether by contract or
|
||||
otherwise, or (ii) ownership of fifty percent (50%) or more of the
|
||||
outstanding shares, or (iii) beneficial ownership of such entity.
|
||||
|
||||
"You" (or "Your") shall mean an individual or Legal Entity
|
||||
exercising permissions granted by this License.
|
||||
|
||||
"Source" form shall mean the preferred form for making modifications,
|
||||
including but not limited to software source code, documentation
|
||||
source, and configuration files.
|
||||
|
||||
"Object" form shall mean any form resulting from mechanical
|
||||
transformation or translation of a Source form, including but
|
||||
not limited to compiled object code, generated documentation,
|
||||
and conversions to other media types.
|
||||
|
||||
"Work" shall mean the work of authorship, whether in Source or
|
||||
Object form, made available under the License, as indicated by a
|
||||
copyright notice that is included in or attached to the work
|
||||
(an example is provided in the Appendix below).
|
||||
|
||||
"Derivative Works" shall mean any work, whether in Source or Object
|
||||
form, that is based on (or derived from) the Work and for which the
|
||||
editorial revisions, annotations, elaborations, or other modifications
|
||||
represent, as a whole, an original work of authorship. For the purposes
|
||||
of this License, Derivative Works shall not include works that remain
|
||||
separable from, or merely link (or bind by name) to the interfaces of,
|
||||
the Work and Derivative Works thereof.
|
||||
|
||||
"Contribution" shall mean any work of authorship, including
|
||||
the original version of the Work and any modifications or additions
|
||||
to that Work or Derivative Works thereof, that is intentionally
|
||||
submitted to Licensor for inclusion in the Work by the copyright owner
|
||||
or by an individual or Legal Entity authorized to submit on behalf of
|
||||
the copyright owner. For the purposes of this definition, "submitted"
|
||||
means any form of electronic, verbal, or written communication sent
|
||||
to the Licensor or its representatives, including but not limited to
|
||||
communication on electronic mailing lists, source code control systems,
|
||||
and issue tracking systems that are managed by, or on behalf of, the
|
||||
Licensor for the purpose of discussing and improving the Work, but
|
||||
excluding communication that is conspicuously marked or otherwise
|
||||
designated in writing by the copyright owner as "Not a Contribution."
|
||||
|
||||
"Contributor" shall mean Licensor and any individual or Legal Entity
|
||||
on behalf of whom a Contribution has been received by Licensor and
|
||||
subsequently incorporated within the Work.
|
||||
|
||||
2. Grant of Copyright License. Subject to the terms and conditions of
|
||||
this License, each Contributor hereby grants to You a perpetual,
|
||||
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
|
||||
copyright license to reproduce, prepare Derivative Works of,
|
||||
publicly display, publicly perform, sublicense, and distribute the
|
||||
Work and such Derivative Works in Source or Object form.
|
||||
|
||||
3. Grant of Patent License. Subject to the terms and conditions of
|
||||
this License, each Contributor hereby grants to You a perpetual,
|
||||
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
|
||||
(except as stated in this section) patent license to make, have made,
|
||||
use, offer to sell, sell, import, and otherwise transfer the Work,
|
||||
where such license applies only to those patent claims licensable
|
||||
by such Contributor that are necessarily infringed by their
|
||||
Contribution(s) alone or by combination of their Contribution(s)
|
||||
with the Work to which such Contribution(s) was submitted. If You
|
||||
institute patent litigation against any entity (including a
|
||||
cross-claim or counterclaim in a lawsuit) alleging that the Work
|
||||
or a Contribution incorporated within the Work constitutes direct
|
||||
or contributory patent infringement, then any patent licenses
|
||||
granted to You under this License for that Work shall terminate
|
||||
as of the date such litigation is filed.
|
||||
|
||||
4. Redistribution. You may reproduce and distribute copies of the
|
||||
Work or Derivative Works thereof in any medium, with or without
|
||||
modifications, and in Source or Object form, provided that You
|
||||
meet the following conditions:
|
||||
|
||||
(a) You must give any other recipients of the Work or
|
||||
Derivative Works a copy of this License; and
|
||||
|
||||
(b) You must cause any modified files to carry prominent notices
|
||||
stating that You changed the files; and
|
||||
|
||||
(c) You must retain, in the Source form of any Derivative Works
|
||||
that You distribute, all copyright, patent, trademark, and
|
||||
attribution notices from the Source form of the Work,
|
||||
excluding those notices that do not pertain to any part of
|
||||
the Derivative Works; and
|
||||
|
||||
(d) If the Work includes a "NOTICE" text file as part of its
|
||||
distribution, then any Derivative Works that You distribute must
|
||||
include a readable copy of the attribution notices contained
|
||||
within such NOTICE file, excluding those notices that do not
|
||||
pertain to any part of the Derivative Works, in at least one
|
||||
of the following places: within a NOTICE text file distributed
|
||||
as part of the Derivative Works; within the Source form or
|
||||
documentation, if provided along with the Derivative Works; or,
|
||||
within a display generated by the Derivative Works, if and
|
||||
wherever such third-party notices normally appear. The contents
|
||||
of the NOTICE file are for informational purposes only and
|
||||
do not modify the License. You may add Your own attribution
|
||||
notices within Derivative Works that You distribute, alongside
|
||||
or as an addendum to the NOTICE text from the Work, provided
|
||||
that such additional attribution notices cannot be construed
|
||||
as modifying the License.
|
||||
|
||||
You may add Your own copyright statement to Your modifications and
|
||||
may provide additional or different license terms and conditions
|
||||
for use, reproduction, or distribution of Your modifications, or
|
||||
for any such Derivative Works as a whole, provided Your use,
|
||||
reproduction, and distribution of the Work otherwise complies with
|
||||
the conditions stated in this License.
|
||||
|
||||
5. Submission of Contributions. Unless You explicitly state otherwise,
|
||||
any Contribution intentionally submitted for inclusion in the Work
|
||||
by You to the Licensor shall be under the terms and conditions of
|
||||
this License, without any additional terms or conditions.
|
||||
Notwithstanding the above, nothing herein shall supersede or modify
|
||||
the terms of any separate license agreement you may have executed
|
||||
with Licensor regarding such Contributions.
|
||||
|
||||
6. Trademarks. This License does not grant permission to use the trade
|
||||
names, trademarks, service marks, or product names of the Licensor,
|
||||
except as required for reasonable and customary use in describing the
|
||||
origin of the Work and reproducing the content of the NOTICE file.
|
||||
|
||||
7. Disclaimer of Warranty. Unless required by applicable law or
|
||||
agreed to in writing, Licensor provides the Work (and each
|
||||
Contributor provides its Contributions) on an "AS IS" BASIS,
|
||||
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
|
||||
implied, including, without limitation, any warranties or conditions
|
||||
of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
|
||||
PARTICULAR PURPOSE. You are solely responsible for determining the
|
||||
appropriateness of using or redistributing the Work and assume any
|
||||
risks associated with Your exercise of permissions under this License.
|
||||
|
||||
8. Limitation of Liability. In no event and under no legal theory,
|
||||
whether in tort (including negligence), contract, or otherwise,
|
||||
unless required by applicable law (such as deliberate and grossly
|
||||
negligent acts) or agreed to in writing, shall any Contributor be
|
||||
liable to You for damages, including any direct, indirect, special,
|
||||
incidental, or consequential damages of any character arising as a
|
||||
result of this License or out of the use or inability to use the
|
||||
Work (including but not limited to damages for loss of goodwill,
|
||||
work stoppage, computer failure or malfunction, or any and all
|
||||
other commercial damages or losses), even if such Contributor
|
||||
has been advised of the possibility of such damages.
|
||||
|
||||
9. Accepting Warranty or Additional Liability. While redistributing
|
||||
the Work or Derivative Works thereof, You may choose to offer,
|
||||
and charge a fee for, acceptance of support, warranty, indemnity,
|
||||
or other liability obligations and/or rights consistent with this
|
||||
License. However, in accepting such obligations, You may act only
|
||||
on Your own behalf and on Your sole responsibility, not on behalf
|
||||
of any other Contributor, and only if You agree to indemnify,
|
||||
defend, and hold each Contributor harmless for any liability
|
||||
incurred by, or claims asserted against, such Contributor by reason
|
||||
of your accepting any such warranty or additional liability.
|
||||
|
||||
END OF TERMS AND CONDITIONS
|
||||
|
||||
APPENDIX: How to apply the Apache License to your work.
|
||||
|
||||
To apply the Apache License to your work, attach the following
|
||||
boilerplate notice, with the fields enclosed by brackets "{}"
|
||||
replaced with your own identifying information. (Don't include
|
||||
the brackets!) The text should be enclosed in the appropriate
|
||||
comment syntax for the file format. We also recommend that a
|
||||
file or class name and description of purpose be included on the
|
||||
same "printed page" as the copyright notice for easier
|
||||
identification within third-party archives.
|
||||
|
||||
Copyright {yyyy} {name of copyright owner}
|
||||
|
||||
Licensed under the Apache License, Version 2.0 (the "License");
|
||||
you may not use this file except in compliance with the License.
|
||||
You may obtain a copy of the License at
|
||||
|
||||
http://www.apache.org/licenses/LICENSE-2.0
|
||||
|
||||
Unless required by applicable law or agreed to in writing, software
|
||||
distributed under the License is distributed on an "AS IS" BASIS,
|
||||
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
See the License for the specific language governing permissions and
|
||||
limitations under the License.
|
||||
29
backend/node_modules/@aws-crypto/sha256-js/README.md
generated
vendored
Normal file
29
backend/node_modules/@aws-crypto/sha256-js/README.md
generated
vendored
Normal file
@@ -0,0 +1,29 @@
|
||||
# crypto-sha256-js
|
||||
|
||||
A pure JS implementation SHA256.
|
||||
|
||||
## Usage
|
||||
|
||||
- To hash "some data"
|
||||
```
|
||||
import {Sha256} from '@aws-crypto/sha256-js';
|
||||
|
||||
const hash = new Sha256();
|
||||
hash.update('some data');
|
||||
const result = await hash.digest();
|
||||
|
||||
```
|
||||
|
||||
- To hmac "some data" with "a key"
|
||||
```
|
||||
import {Sha256} from '@aws-crypto/sha256-js';
|
||||
|
||||
const hash = new Sha256('a key');
|
||||
hash.update('some data');
|
||||
const result = await hash.digest();
|
||||
|
||||
```
|
||||
|
||||
## Test
|
||||
|
||||
`npm test`
|
||||
17
backend/node_modules/@aws-crypto/sha256-js/build/main/RawSha256.d.ts
generated
vendored
Normal file
17
backend/node_modules/@aws-crypto/sha256-js/build/main/RawSha256.d.ts
generated
vendored
Normal file
@@ -0,0 +1,17 @@
|
||||
/**
|
||||
* @internal
|
||||
*/
|
||||
export declare class RawSha256 {
|
||||
private state;
|
||||
private temp;
|
||||
private buffer;
|
||||
private bufferLength;
|
||||
private bytesHashed;
|
||||
/**
|
||||
* @internal
|
||||
*/
|
||||
finished: boolean;
|
||||
update(data: Uint8Array): void;
|
||||
digest(): Uint8Array;
|
||||
private hashBuffer;
|
||||
}
|
||||
124
backend/node_modules/@aws-crypto/sha256-js/build/main/RawSha256.js
generated
vendored
Normal file
124
backend/node_modules/@aws-crypto/sha256-js/build/main/RawSha256.js
generated
vendored
Normal file
@@ -0,0 +1,124 @@
|
||||
"use strict";
|
||||
Object.defineProperty(exports, "__esModule", { value: true });
|
||||
exports.RawSha256 = void 0;
|
||||
var constants_1 = require("./constants");
|
||||
/**
|
||||
* @internal
|
||||
*/
|
||||
var RawSha256 = /** @class */ (function () {
|
||||
function RawSha256() {
|
||||
this.state = Int32Array.from(constants_1.INIT);
|
||||
this.temp = new Int32Array(64);
|
||||
this.buffer = new Uint8Array(64);
|
||||
this.bufferLength = 0;
|
||||
this.bytesHashed = 0;
|
||||
/**
|
||||
* @internal
|
||||
*/
|
||||
this.finished = false;
|
||||
}
|
||||
RawSha256.prototype.update = function (data) {
|
||||
if (this.finished) {
|
||||
throw new Error("Attempted to update an already finished hash.");
|
||||
}
|
||||
var position = 0;
|
||||
var byteLength = data.byteLength;
|
||||
this.bytesHashed += byteLength;
|
||||
if (this.bytesHashed * 8 > constants_1.MAX_HASHABLE_LENGTH) {
|
||||
throw new Error("Cannot hash more than 2^53 - 1 bits");
|
||||
}
|
||||
while (byteLength > 0) {
|
||||
this.buffer[this.bufferLength++] = data[position++];
|
||||
byteLength--;
|
||||
if (this.bufferLength === constants_1.BLOCK_SIZE) {
|
||||
this.hashBuffer();
|
||||
this.bufferLength = 0;
|
||||
}
|
||||
}
|
||||
};
|
||||
RawSha256.prototype.digest = function () {
|
||||
if (!this.finished) {
|
||||
var bitsHashed = this.bytesHashed * 8;
|
||||
var bufferView = new DataView(this.buffer.buffer, this.buffer.byteOffset, this.buffer.byteLength);
|
||||
var undecoratedLength = this.bufferLength;
|
||||
bufferView.setUint8(this.bufferLength++, 0x80);
|
||||
// Ensure the final block has enough room for the hashed length
|
||||
if (undecoratedLength % constants_1.BLOCK_SIZE >= constants_1.BLOCK_SIZE - 8) {
|
||||
for (var i = this.bufferLength; i < constants_1.BLOCK_SIZE; i++) {
|
||||
bufferView.setUint8(i, 0);
|
||||
}
|
||||
this.hashBuffer();
|
||||
this.bufferLength = 0;
|
||||
}
|
||||
for (var i = this.bufferLength; i < constants_1.BLOCK_SIZE - 8; i++) {
|
||||
bufferView.setUint8(i, 0);
|
||||
}
|
||||
bufferView.setUint32(constants_1.BLOCK_SIZE - 8, Math.floor(bitsHashed / 0x100000000), true);
|
||||
bufferView.setUint32(constants_1.BLOCK_SIZE - 4, bitsHashed);
|
||||
this.hashBuffer();
|
||||
this.finished = true;
|
||||
}
|
||||
// The value in state is little-endian rather than big-endian, so flip
|
||||
// each word into a new Uint8Array
|
||||
var out = new Uint8Array(constants_1.DIGEST_LENGTH);
|
||||
for (var i = 0; i < 8; i++) {
|
||||
out[i * 4] = (this.state[i] >>> 24) & 0xff;
|
||||
out[i * 4 + 1] = (this.state[i] >>> 16) & 0xff;
|
||||
out[i * 4 + 2] = (this.state[i] >>> 8) & 0xff;
|
||||
out[i * 4 + 3] = (this.state[i] >>> 0) & 0xff;
|
||||
}
|
||||
return out;
|
||||
};
|
||||
RawSha256.prototype.hashBuffer = function () {
|
||||
var _a = this, buffer = _a.buffer, state = _a.state;
|
||||
var state0 = state[0], state1 = state[1], state2 = state[2], state3 = state[3], state4 = state[4], state5 = state[5], state6 = state[6], state7 = state[7];
|
||||
for (var i = 0; i < constants_1.BLOCK_SIZE; i++) {
|
||||
if (i < 16) {
|
||||
this.temp[i] =
|
||||
((buffer[i * 4] & 0xff) << 24) |
|
||||
((buffer[i * 4 + 1] & 0xff) << 16) |
|
||||
((buffer[i * 4 + 2] & 0xff) << 8) |
|
||||
(buffer[i * 4 + 3] & 0xff);
|
||||
}
|
||||
else {
|
||||
var u = this.temp[i - 2];
|
||||
var t1_1 = ((u >>> 17) | (u << 15)) ^ ((u >>> 19) | (u << 13)) ^ (u >>> 10);
|
||||
u = this.temp[i - 15];
|
||||
var t2_1 = ((u >>> 7) | (u << 25)) ^ ((u >>> 18) | (u << 14)) ^ (u >>> 3);
|
||||
this.temp[i] =
|
||||
((t1_1 + this.temp[i - 7]) | 0) + ((t2_1 + this.temp[i - 16]) | 0);
|
||||
}
|
||||
var t1 = ((((((state4 >>> 6) | (state4 << 26)) ^
|
||||
((state4 >>> 11) | (state4 << 21)) ^
|
||||
((state4 >>> 25) | (state4 << 7))) +
|
||||
((state4 & state5) ^ (~state4 & state6))) |
|
||||
0) +
|
||||
((state7 + ((constants_1.KEY[i] + this.temp[i]) | 0)) | 0)) |
|
||||
0;
|
||||
var t2 = ((((state0 >>> 2) | (state0 << 30)) ^
|
||||
((state0 >>> 13) | (state0 << 19)) ^
|
||||
((state0 >>> 22) | (state0 << 10))) +
|
||||
((state0 & state1) ^ (state0 & state2) ^ (state1 & state2))) |
|
||||
0;
|
||||
state7 = state6;
|
||||
state6 = state5;
|
||||
state5 = state4;
|
||||
state4 = (state3 + t1) | 0;
|
||||
state3 = state2;
|
||||
state2 = state1;
|
||||
state1 = state0;
|
||||
state0 = (t1 + t2) | 0;
|
||||
}
|
||||
state[0] += state0;
|
||||
state[1] += state1;
|
||||
state[2] += state2;
|
||||
state[3] += state3;
|
||||
state[4] += state4;
|
||||
state[5] += state5;
|
||||
state[6] += state6;
|
||||
state[7] += state7;
|
||||
};
|
||||
return RawSha256;
|
||||
}());
|
||||
exports.RawSha256 = RawSha256;
|
||||
//# sourceMappingURL=RawSha256.js.map
|
||||
1
backend/node_modules/@aws-crypto/sha256-js/build/main/RawSha256.js.map
generated
vendored
Normal file
1
backend/node_modules/@aws-crypto/sha256-js/build/main/RawSha256.js.map
generated
vendored
Normal file
File diff suppressed because one or more lines are too long
20
backend/node_modules/@aws-crypto/sha256-js/build/main/constants.d.ts
generated
vendored
Normal file
20
backend/node_modules/@aws-crypto/sha256-js/build/main/constants.d.ts
generated
vendored
Normal file
@@ -0,0 +1,20 @@
|
||||
/**
|
||||
* @internal
|
||||
*/
|
||||
export declare const BLOCK_SIZE: number;
|
||||
/**
|
||||
* @internal
|
||||
*/
|
||||
export declare const DIGEST_LENGTH: number;
|
||||
/**
|
||||
* @internal
|
||||
*/
|
||||
export declare const KEY: Uint32Array;
|
||||
/**
|
||||
* @internal
|
||||
*/
|
||||
export declare const INIT: number[];
|
||||
/**
|
||||
* @internal
|
||||
*/
|
||||
export declare const MAX_HASHABLE_LENGTH: number;
|
||||
98
backend/node_modules/@aws-crypto/sha256-js/build/main/constants.js
generated
vendored
Normal file
98
backend/node_modules/@aws-crypto/sha256-js/build/main/constants.js
generated
vendored
Normal file
@@ -0,0 +1,98 @@
|
||||
"use strict";
|
||||
Object.defineProperty(exports, "__esModule", { value: true });
|
||||
exports.MAX_HASHABLE_LENGTH = exports.INIT = exports.KEY = exports.DIGEST_LENGTH = exports.BLOCK_SIZE = void 0;
|
||||
/**
|
||||
* @internal
|
||||
*/
|
||||
exports.BLOCK_SIZE = 64;
|
||||
/**
|
||||
* @internal
|
||||
*/
|
||||
exports.DIGEST_LENGTH = 32;
|
||||
/**
|
||||
* @internal
|
||||
*/
|
||||
exports.KEY = new Uint32Array([
|
||||
0x428a2f98,
|
||||
0x71374491,
|
||||
0xb5c0fbcf,
|
||||
0xe9b5dba5,
|
||||
0x3956c25b,
|
||||
0x59f111f1,
|
||||
0x923f82a4,
|
||||
0xab1c5ed5,
|
||||
0xd807aa98,
|
||||
0x12835b01,
|
||||
0x243185be,
|
||||
0x550c7dc3,
|
||||
0x72be5d74,
|
||||
0x80deb1fe,
|
||||
0x9bdc06a7,
|
||||
0xc19bf174,
|
||||
0xe49b69c1,
|
||||
0xefbe4786,
|
||||
0x0fc19dc6,
|
||||
0x240ca1cc,
|
||||
0x2de92c6f,
|
||||
0x4a7484aa,
|
||||
0x5cb0a9dc,
|
||||
0x76f988da,
|
||||
0x983e5152,
|
||||
0xa831c66d,
|
||||
0xb00327c8,
|
||||
0xbf597fc7,
|
||||
0xc6e00bf3,
|
||||
0xd5a79147,
|
||||
0x06ca6351,
|
||||
0x14292967,
|
||||
0x27b70a85,
|
||||
0x2e1b2138,
|
||||
0x4d2c6dfc,
|
||||
0x53380d13,
|
||||
0x650a7354,
|
||||
0x766a0abb,
|
||||
0x81c2c92e,
|
||||
0x92722c85,
|
||||
0xa2bfe8a1,
|
||||
0xa81a664b,
|
||||
0xc24b8b70,
|
||||
0xc76c51a3,
|
||||
0xd192e819,
|
||||
0xd6990624,
|
||||
0xf40e3585,
|
||||
0x106aa070,
|
||||
0x19a4c116,
|
||||
0x1e376c08,
|
||||
0x2748774c,
|
||||
0x34b0bcb5,
|
||||
0x391c0cb3,
|
||||
0x4ed8aa4a,
|
||||
0x5b9cca4f,
|
||||
0x682e6ff3,
|
||||
0x748f82ee,
|
||||
0x78a5636f,
|
||||
0x84c87814,
|
||||
0x8cc70208,
|
||||
0x90befffa,
|
||||
0xa4506ceb,
|
||||
0xbef9a3f7,
|
||||
0xc67178f2
|
||||
]);
|
||||
/**
|
||||
* @internal
|
||||
*/
|
||||
exports.INIT = [
|
||||
0x6a09e667,
|
||||
0xbb67ae85,
|
||||
0x3c6ef372,
|
||||
0xa54ff53a,
|
||||
0x510e527f,
|
||||
0x9b05688c,
|
||||
0x1f83d9ab,
|
||||
0x5be0cd19
|
||||
];
|
||||
/**
|
||||
* @internal
|
||||
*/
|
||||
exports.MAX_HASHABLE_LENGTH = Math.pow(2, 53) - 1;
|
||||
//# sourceMappingURL=constants.js.map
|
||||
1
backend/node_modules/@aws-crypto/sha256-js/build/main/constants.js.map
generated
vendored
Normal file
1
backend/node_modules/@aws-crypto/sha256-js/build/main/constants.js.map
generated
vendored
Normal file
@@ -0,0 +1 @@
|
||||
{"version":3,"file":"constants.js","sourceRoot":"","sources":["../../src/constants.ts"],"names":[],"mappings":";;;AAAA;;GAEG;AACU,QAAA,UAAU,GAAW,EAAE,CAAC;AAErC;;GAEG;AACU,QAAA,aAAa,GAAW,EAAE,CAAC;AAExC;;GAEG;AACU,QAAA,GAAG,GAAG,IAAI,WAAW,CAAC;IACjC,UAAU;IACV,UAAU;IACV,UAAU;IACV,UAAU;IACV,UAAU;IACV,UAAU;IACV,UAAU;IACV,UAAU;IACV,UAAU;IACV,UAAU;IACV,UAAU;IACV,UAAU;IACV,UAAU;IACV,UAAU;IACV,UAAU;IACV,UAAU;IACV,UAAU;IACV,UAAU;IACV,UAAU;IACV,UAAU;IACV,UAAU;IACV,UAAU;IACV,UAAU;IACV,UAAU;IACV,UAAU;IACV,UAAU;IACV,UAAU;IACV,UAAU;IACV,UAAU;IACV,UAAU;IACV,UAAU;IACV,UAAU;IACV,UAAU;IACV,UAAU;IACV,UAAU;IACV,UAAU;IACV,UAAU;IACV,UAAU;IACV,UAAU;IACV,UAAU;IACV,UAAU;IACV,UAAU;IACV,UAAU;IACV,UAAU;IACV,UAAU;IACV,UAAU;IACV,UAAU;IACV,UAAU;IACV,UAAU;IACV,UAAU;IACV,UAAU;IACV,UAAU;IACV,UAAU;IACV,UAAU;IACV,UAAU;IACV,UAAU;IACV,UAAU;IACV,UAAU;IACV,UAAU;IACV,UAAU;IACV,UAAU;IACV,UAAU;IACV,UAAU;IACV,UAAU;CACX,CAAC,CAAC;AAEH;;GAEG;AACU,QAAA,IAAI,GAAG;IAClB,UAAU;IACV,UAAU;IACV,UAAU;IACV,UAAU;IACV,UAAU;IACV,UAAU;IACV,UAAU;IACV,UAAU;CACX,CAAC;AAEF;;GAEG;AACU,QAAA,mBAAmB,GAAG,SAAA,CAAC,EAAI,EAAE,CAAA,GAAG,CAAC,CAAC"}
|
||||
1
backend/node_modules/@aws-crypto/sha256-js/build/main/index.d.ts
generated
vendored
Normal file
1
backend/node_modules/@aws-crypto/sha256-js/build/main/index.d.ts
generated
vendored
Normal file
@@ -0,0 +1 @@
|
||||
export * from "./jsSha256";
|
||||
5
backend/node_modules/@aws-crypto/sha256-js/build/main/index.js
generated
vendored
Normal file
5
backend/node_modules/@aws-crypto/sha256-js/build/main/index.js
generated
vendored
Normal file
@@ -0,0 +1,5 @@
|
||||
"use strict";
|
||||
Object.defineProperty(exports, "__esModule", { value: true });
|
||||
var tslib_1 = require("tslib");
|
||||
tslib_1.__exportStar(require("./jsSha256"), exports);
|
||||
//# sourceMappingURL=index.js.map
|
||||
1
backend/node_modules/@aws-crypto/sha256-js/build/main/index.js.map
generated
vendored
Normal file
1
backend/node_modules/@aws-crypto/sha256-js/build/main/index.js.map
generated
vendored
Normal file
@@ -0,0 +1 @@
|
||||
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/index.ts"],"names":[],"mappings":";;;AAAA,qDAA2B"}
|
||||
12
backend/node_modules/@aws-crypto/sha256-js/build/main/jsSha256.d.ts
generated
vendored
Normal file
12
backend/node_modules/@aws-crypto/sha256-js/build/main/jsSha256.d.ts
generated
vendored
Normal file
@@ -0,0 +1,12 @@
|
||||
import { Checksum, SourceData } from "@aws-sdk/types";
|
||||
export declare class Sha256 implements Checksum {
|
||||
private readonly secret?;
|
||||
private hash;
|
||||
private outer?;
|
||||
private error;
|
||||
constructor(secret?: SourceData);
|
||||
update(toHash: SourceData): void;
|
||||
digestSync(): Uint8Array;
|
||||
digest(): Promise<Uint8Array>;
|
||||
reset(): void;
|
||||
}
|
||||
85
backend/node_modules/@aws-crypto/sha256-js/build/main/jsSha256.js
generated
vendored
Normal file
85
backend/node_modules/@aws-crypto/sha256-js/build/main/jsSha256.js
generated
vendored
Normal file
@@ -0,0 +1,85 @@
|
||||
"use strict";
|
||||
Object.defineProperty(exports, "__esModule", { value: true });
|
||||
exports.Sha256 = void 0;
|
||||
var tslib_1 = require("tslib");
|
||||
var constants_1 = require("./constants");
|
||||
var RawSha256_1 = require("./RawSha256");
|
||||
var util_1 = require("@aws-crypto/util");
|
||||
var Sha256 = /** @class */ (function () {
|
||||
function Sha256(secret) {
|
||||
this.secret = secret;
|
||||
this.hash = new RawSha256_1.RawSha256();
|
||||
this.reset();
|
||||
}
|
||||
Sha256.prototype.update = function (toHash) {
|
||||
if ((0, util_1.isEmptyData)(toHash) || this.error) {
|
||||
return;
|
||||
}
|
||||
try {
|
||||
this.hash.update((0, util_1.convertToBuffer)(toHash));
|
||||
}
|
||||
catch (e) {
|
||||
this.error = e;
|
||||
}
|
||||
};
|
||||
/* This synchronous method keeps compatibility
|
||||
* with the v2 aws-sdk.
|
||||
*/
|
||||
Sha256.prototype.digestSync = function () {
|
||||
if (this.error) {
|
||||
throw this.error;
|
||||
}
|
||||
if (this.outer) {
|
||||
if (!this.outer.finished) {
|
||||
this.outer.update(this.hash.digest());
|
||||
}
|
||||
return this.outer.digest();
|
||||
}
|
||||
return this.hash.digest();
|
||||
};
|
||||
/* The underlying digest method here is synchronous.
|
||||
* To keep the same interface with the other hash functions
|
||||
* the default is to expose this as an async method.
|
||||
* However, it can sometimes be useful to have a sync method.
|
||||
*/
|
||||
Sha256.prototype.digest = function () {
|
||||
return tslib_1.__awaiter(this, void 0, void 0, function () {
|
||||
return tslib_1.__generator(this, function (_a) {
|
||||
return [2 /*return*/, this.digestSync()];
|
||||
});
|
||||
});
|
||||
};
|
||||
Sha256.prototype.reset = function () {
|
||||
this.hash = new RawSha256_1.RawSha256();
|
||||
if (this.secret) {
|
||||
this.outer = new RawSha256_1.RawSha256();
|
||||
var inner = bufferFromSecret(this.secret);
|
||||
var outer = new Uint8Array(constants_1.BLOCK_SIZE);
|
||||
outer.set(inner);
|
||||
for (var i = 0; i < constants_1.BLOCK_SIZE; i++) {
|
||||
inner[i] ^= 0x36;
|
||||
outer[i] ^= 0x5c;
|
||||
}
|
||||
this.hash.update(inner);
|
||||
this.outer.update(outer);
|
||||
// overwrite the copied key in memory
|
||||
for (var i = 0; i < inner.byteLength; i++) {
|
||||
inner[i] = 0;
|
||||
}
|
||||
}
|
||||
};
|
||||
return Sha256;
|
||||
}());
|
||||
exports.Sha256 = Sha256;
|
||||
function bufferFromSecret(secret) {
|
||||
var input = (0, util_1.convertToBuffer)(secret);
|
||||
if (input.byteLength > constants_1.BLOCK_SIZE) {
|
||||
var bufferHash = new RawSha256_1.RawSha256();
|
||||
bufferHash.update(input);
|
||||
input = bufferHash.digest();
|
||||
}
|
||||
var buffer = new Uint8Array(constants_1.BLOCK_SIZE);
|
||||
buffer.set(input);
|
||||
return buffer;
|
||||
}
|
||||
//# sourceMappingURL=jsSha256.js.map
|
||||
1
backend/node_modules/@aws-crypto/sha256-js/build/main/jsSha256.js.map
generated
vendored
Normal file
1
backend/node_modules/@aws-crypto/sha256-js/build/main/jsSha256.js.map
generated
vendored
Normal file
@@ -0,0 +1 @@
|
||||
{"version":3,"file":"jsSha256.js","sourceRoot":"","sources":["../../src/jsSha256.ts"],"names":[],"mappings":";;;;AAAA,yCAAyC;AACzC,yCAAwC;AAExC,yCAAgE;AAEhE;IAME,gBAAY,MAAmB;QAC7B,IAAI,CAAC,MAAM,GAAG,MAAM,CAAC;QACrB,IAAI,CAAC,IAAI,GAAG,IAAI,qBAAS,EAAE,CAAC;QAC5B,IAAI,CAAC,KAAK,EAAE,CAAC;IACf,CAAC;IAED,uBAAM,GAAN,UAAO,MAAkB;QACvB,IAAI,IAAA,kBAAW,EAAC,MAAM,CAAC,IAAI,IAAI,CAAC,KAAK,EAAE;YACrC,OAAO;SACR;QAED,IAAI;YACF,IAAI,CAAC,IAAI,CAAC,MAAM,CAAC,IAAA,sBAAe,EAAC,MAAM,CAAC,CAAC,CAAC;SAC3C;QAAC,OAAO,CAAC,EAAE;YACV,IAAI,CAAC,KAAK,GAAG,CAAC,CAAC;SAChB;IACH,CAAC;IAED;;OAEG;IACH,2BAAU,GAAV;QACE,IAAI,IAAI,CAAC,KAAK,EAAE;YACd,MAAM,IAAI,CAAC,KAAK,CAAC;SAClB;QAED,IAAI,IAAI,CAAC,KAAK,EAAE;YACd,IAAI,CAAC,IAAI,CAAC,KAAK,CAAC,QAAQ,EAAE;gBACxB,IAAI,CAAC,KAAK,CAAC,MAAM,CAAC,IAAI,CAAC,IAAI,CAAC,MAAM,EAAE,CAAC,CAAC;aACvC;YAED,OAAO,IAAI,CAAC,KAAK,CAAC,MAAM,EAAE,CAAC;SAC5B;QAED,OAAO,IAAI,CAAC,IAAI,CAAC,MAAM,EAAE,CAAC;IAC5B,CAAC;IAED;;;;OAIG;IACG,uBAAM,GAAZ;;;gBACE,sBAAO,IAAI,CAAC,UAAU,EAAE,EAAC;;;KAC1B;IAED,sBAAK,GAAL;QACE,IAAI,CAAC,IAAI,GAAG,IAAI,qBAAS,EAAE,CAAC;QAC5B,IAAI,IAAI,CAAC,MAAM,EAAE;YACf,IAAI,CAAC,KAAK,GAAG,IAAI,qBAAS,EAAE,CAAC;YAC7B,IAAM,KAAK,GAAG,gBAAgB,CAAC,IAAI,CAAC,MAAM,CAAC,CAAC;YAC5C,IAAM,KAAK,GAAG,IAAI,UAAU,CAAC,sBAAU,CAAC,CAAC;YACzC,KAAK,CAAC,GAAG,CAAC,KAAK,CAAC,CAAC;YAEjB,KAAK,IAAI,CAAC,GAAG,CAAC,EAAE,CAAC,GAAG,sBAAU,EAAE,CAAC,EAAE,EAAE;gBACnC,KAAK,CAAC,CAAC,CAAC,IAAI,IAAI,CAAC;gBACjB,KAAK,CAAC,CAAC,CAAC,IAAI,IAAI,CAAC;aAClB;YAED,IAAI,CAAC,IAAI,CAAC,MAAM,CAAC,KAAK,CAAC,CAAC;YACxB,IAAI,CAAC,KAAK,CAAC,MAAM,CAAC,KAAK,CAAC,CAAC;YAEzB,qCAAqC;YACrC,KAAK,IAAI,CAAC,GAAG,CAAC,EAAE,CAAC,GAAG,KAAK,CAAC,UAAU,EAAE,CAAC,EAAE,EAAE;gBACzC,KAAK,CAAC,CAAC,CAAC,GAAG,CAAC,CAAC;aACd;SACF;IACH,CAAC;IACH,aAAC;AAAD,CAAC,AA1ED,IA0EC;AA1EY,wBAAM;AA4EnB,SAAS,gBAAgB,CAAC,MAAkB;IAC1C,IAAI,KAAK,GAAG,IAAA,sBAAe,EAAC,MAAM,CAAC,CAAC;IAEpC,IAAI,KAAK,CAAC,UAAU,GAAG,sBAAU,EAAE;QACjC,IAAM,UAAU,GAAG,IAAI,qBAAS,EAAE,CAAC;QACnC,UAAU,CAAC,MAAM,CAAC,KAAK,CAAC,CAAC;QACzB,KAAK,GAAG,UAAU,CAAC,MAAM,EAAE,CAAC;KAC7B;IAED,IAAM,MAAM,GAAG,IAAI,UAAU,CAAC,sBAAU,CAAC,CAAC;IAC1C,MAAM,CAAC,GAAG,CAAC,KAAK,CAAC,CAAC;IAClB,OAAO,MAAM,CAAC;AAChB,CAAC"}
|
||||
5
backend/node_modules/@aws-crypto/sha256-js/build/main/knownHashes.fixture.d.ts
generated
vendored
Normal file
5
backend/node_modules/@aws-crypto/sha256-js/build/main/knownHashes.fixture.d.ts
generated
vendored
Normal file
@@ -0,0 +1,5 @@
|
||||
export declare const hashTestVectors: Array<[Uint8Array, Uint8Array]>;
|
||||
/**
|
||||
* @see https://tools.ietf.org/html/rfc4231
|
||||
*/
|
||||
export declare const hmacTestVectors: Array<[Uint8Array, Uint8Array, Uint8Array]>;
|
||||
322
backend/node_modules/@aws-crypto/sha256-js/build/main/knownHashes.fixture.js
generated
vendored
Normal file
322
backend/node_modules/@aws-crypto/sha256-js/build/main/knownHashes.fixture.js
generated
vendored
Normal file
@@ -0,0 +1,322 @@
|
||||
"use strict";
|
||||
Object.defineProperty(exports, "__esModule", { value: true });
|
||||
exports.hmacTestVectors = exports.hashTestVectors = void 0;
|
||||
var util_hex_encoding_1 = require("@aws-sdk/util-hex-encoding");
|
||||
var millionChars = new Uint8Array(1000000);
|
||||
for (var i = 0; i < 1000000; i++) {
|
||||
millionChars[i] = 97;
|
||||
}
|
||||
exports.hashTestVectors = [
|
||||
[
|
||||
Uint8Array.from([97, 98, 99]),
|
||||
(0, util_hex_encoding_1.fromHex)("ba7816bf8f01cfea414140de5dae2223b00361a396177a9cb410ff61f20015ad")
|
||||
],
|
||||
[
|
||||
new Uint8Array(0),
|
||||
(0, util_hex_encoding_1.fromHex)("e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855")
|
||||
],
|
||||
[
|
||||
(0, util_hex_encoding_1.fromHex)("61"),
|
||||
(0, util_hex_encoding_1.fromHex)("ca978112ca1bbdcafac231b39a23dc4da786eff8147c4e72b9807785afee48bb")
|
||||
],
|
||||
[
|
||||
(0, util_hex_encoding_1.fromHex)("6161"),
|
||||
(0, util_hex_encoding_1.fromHex)("961b6dd3ede3cb8ecbaacbd68de040cd78eb2ed5889130cceb4c49268ea4d506")
|
||||
],
|
||||
[
|
||||
(0, util_hex_encoding_1.fromHex)("616161"),
|
||||
(0, util_hex_encoding_1.fromHex)("9834876dcfb05cb167a5c24953eba58c4ac89b1adf57f28f2f9d09af107ee8f0")
|
||||
],
|
||||
[
|
||||
(0, util_hex_encoding_1.fromHex)("61616161"),
|
||||
(0, util_hex_encoding_1.fromHex)("61be55a8e2f6b4e172338bddf184d6dbee29c98853e0a0485ecee7f27b9af0b4")
|
||||
],
|
||||
[
|
||||
(0, util_hex_encoding_1.fromHex)("6161616161"),
|
||||
(0, util_hex_encoding_1.fromHex)("ed968e840d10d2d313a870bc131a4e2c311d7ad09bdf32b3418147221f51a6e2")
|
||||
],
|
||||
[
|
||||
(0, util_hex_encoding_1.fromHex)("616161616161"),
|
||||
(0, util_hex_encoding_1.fromHex)("ed02457b5c41d964dbd2f2a609d63fe1bb7528dbe55e1abf5b52c249cd735797")
|
||||
],
|
||||
[
|
||||
(0, util_hex_encoding_1.fromHex)("61616161616161"),
|
||||
(0, util_hex_encoding_1.fromHex)("e46240714b5db3a23eee60479a623efba4d633d27fe4f03c904b9e219a7fbe60")
|
||||
],
|
||||
[
|
||||
(0, util_hex_encoding_1.fromHex)("6161616161616161"),
|
||||
(0, util_hex_encoding_1.fromHex)("1f3ce40415a2081fa3eee75fc39fff8e56c22270d1a978a7249b592dcebd20b4")
|
||||
],
|
||||
[
|
||||
(0, util_hex_encoding_1.fromHex)("616161616161616161"),
|
||||
(0, util_hex_encoding_1.fromHex)("f2aca93b80cae681221f0445fa4e2cae8a1f9f8fa1e1741d9639caad222f537d")
|
||||
],
|
||||
[
|
||||
(0, util_hex_encoding_1.fromHex)("61616161616161616161"),
|
||||
(0, util_hex_encoding_1.fromHex)("bf2cb58a68f684d95a3b78ef8f661c9a4e5b09e82cc8f9cc88cce90528caeb27")
|
||||
],
|
||||
[
|
||||
(0, util_hex_encoding_1.fromHex)("6161616161616161616161"),
|
||||
(0, util_hex_encoding_1.fromHex)("28cb017dfc99073aa1b47c1b30f413e3ce774c4991eb4158de50f9dbb36d8043")
|
||||
],
|
||||
[
|
||||
(0, util_hex_encoding_1.fromHex)("616161616161616161616161"),
|
||||
(0, util_hex_encoding_1.fromHex)("f24abc34b13fade76e805799f71187da6cd90b9cac373ae65ed57f143bd664e5")
|
||||
],
|
||||
[
|
||||
(0, util_hex_encoding_1.fromHex)("61616161616161616161616161"),
|
||||
(0, util_hex_encoding_1.fromHex)("a689d786e81340e45511dec6c7ab2d978434e5db123362450fe10cfac70d19d0")
|
||||
],
|
||||
[
|
||||
(0, util_hex_encoding_1.fromHex)("6161616161616161616161616161"),
|
||||
(0, util_hex_encoding_1.fromHex)("82cab7df0abfb9d95dca4e5937ce2968c798c726fea48c016bf9763221efda13")
|
||||
],
|
||||
[
|
||||
(0, util_hex_encoding_1.fromHex)("616161616161616161616161616161"),
|
||||
(0, util_hex_encoding_1.fromHex)("ef2df0b539c6c23de0f4cbe42648c301ae0e22e887340a4599fb4ef4e2678e48")
|
||||
],
|
||||
[
|
||||
(0, util_hex_encoding_1.fromHex)("61616161616161616161616161616161"),
|
||||
(0, util_hex_encoding_1.fromHex)("0c0beacef8877bbf2416eb00f2b5dc96354e26dd1df5517320459b1236860f8c")
|
||||
],
|
||||
[
|
||||
(0, util_hex_encoding_1.fromHex)("6161616161616161616161616161616161"),
|
||||
(0, util_hex_encoding_1.fromHex)("b860666ee2966dd8f903be44ee605c6e1366f926d9f17a8f49937d11624eb99d")
|
||||
],
|
||||
[
|
||||
(0, util_hex_encoding_1.fromHex)("616161616161616161616161616161616161"),
|
||||
(0, util_hex_encoding_1.fromHex)("c926defaaa3d13eda2fc63a553bb7fb7326bece6e7cb67ca5296e4727d89bab4")
|
||||
],
|
||||
[
|
||||
(0, util_hex_encoding_1.fromHex)("61616161616161616161616161616161616161"),
|
||||
(0, util_hex_encoding_1.fromHex)("a0b4aaab8a966e2193ba172d68162c4656860197f256b5f45f0203397ff3f99c")
|
||||
],
|
||||
[
|
||||
(0, util_hex_encoding_1.fromHex)("6161616161616161616161616161616161616161"),
|
||||
(0, util_hex_encoding_1.fromHex)("42492da06234ad0ac76f5d5debdb6d1ae027cffbe746a1c13b89bb8bc0139137")
|
||||
],
|
||||
[
|
||||
(0, util_hex_encoding_1.fromHex)("616161616161616161616161616161616161616161"),
|
||||
(0, util_hex_encoding_1.fromHex)("7df8e299c834de198e264c3e374bc58ecd9382252a705c183beb02f275571e3b")
|
||||
],
|
||||
[
|
||||
(0, util_hex_encoding_1.fromHex)("61616161616161616161616161616161616161616161"),
|
||||
(0, util_hex_encoding_1.fromHex)("ec7c494df6d2a7ea36668d656e6b8979e33641bfea378c15038af3964db057a3")
|
||||
],
|
||||
[
|
||||
(0, util_hex_encoding_1.fromHex)("6161616161616161616161616161616161616161616161"),
|
||||
(0, util_hex_encoding_1.fromHex)("897d3e95b65f26676081f8b9f3a98b6ee4424566303e8d4e7c7522ebae219eab")
|
||||
],
|
||||
[
|
||||
(0, util_hex_encoding_1.fromHex)("616161616161616161616161616161616161616161616161"),
|
||||
(0, util_hex_encoding_1.fromHex)("09f61f8d9cd65e6a0c258087c485b6293541364e42bd97b2d7936580c8aa3c54")
|
||||
],
|
||||
[
|
||||
(0, util_hex_encoding_1.fromHex)("61616161616161616161616161616161616161616161616161"),
|
||||
(0, util_hex_encoding_1.fromHex)("2f521e2a7d0bd812cbc035f4ed6806eb8d851793b04ba147e8f66b72f5d1f20f")
|
||||
],
|
||||
[
|
||||
(0, util_hex_encoding_1.fromHex)("6161616161616161616161616161616161616161616161616161"),
|
||||
(0, util_hex_encoding_1.fromHex)("9976d549a25115dab4e36d0c1fb8f31cb07da87dd83275977360eb7dc09e88de")
|
||||
],
|
||||
[
|
||||
(0, util_hex_encoding_1.fromHex)("616161616161616161616161616161616161616161616161616161"),
|
||||
(0, util_hex_encoding_1.fromHex)("cc0616e61cbd6e8e5e34e9fb2d320f37de915820206f5696c31f1fbd24aa16de")
|
||||
],
|
||||
[
|
||||
(0, util_hex_encoding_1.fromHex)("61616161616161616161616161616161616161616161616161616161"),
|
||||
(0, util_hex_encoding_1.fromHex)("9c547cb8115a44883b9f70ba68f75117cd55359c92611875e386f8af98c172ab")
|
||||
],
|
||||
[
|
||||
(0, util_hex_encoding_1.fromHex)("6161616161616161616161616161616161616161616161616161616161"),
|
||||
(0, util_hex_encoding_1.fromHex)("6913c9c7fd42fe23df8b6bcd4dbaf1c17748948d97f2980b432319c39eddcf6c")
|
||||
],
|
||||
[
|
||||
(0, util_hex_encoding_1.fromHex)("616161616161616161616161616161616161616161616161616161616161"),
|
||||
(0, util_hex_encoding_1.fromHex)("3a54fc0cbc0b0ef48b6507b7788096235d10292dd3ae24e22f5aa062d4f9864a")
|
||||
],
|
||||
[
|
||||
(0, util_hex_encoding_1.fromHex)("61616161616161616161616161616161616161616161616161616161616161"),
|
||||
(0, util_hex_encoding_1.fromHex)("61c60b487d1a921e0bcc9bf853dda0fb159b30bf57b2e2d2c753b00be15b5a09")
|
||||
],
|
||||
[
|
||||
(0, util_hex_encoding_1.fromHex)("6161616161616161616161616161616161616161616161616161616161616161"),
|
||||
(0, util_hex_encoding_1.fromHex)("3ba3f5f43b92602683c19aee62a20342b084dd5971ddd33808d81a328879a547")
|
||||
],
|
||||
[
|
||||
(0, util_hex_encoding_1.fromHex)("616161616161616161616161616161616161616161616161616161616161616161"),
|
||||
(0, util_hex_encoding_1.fromHex)("852785c805c77e71a22340a54e9d95933ed49121e7d2bf3c2d358854bc1359ea")
|
||||
],
|
||||
[
|
||||
(0, util_hex_encoding_1.fromHex)("61616161616161616161616161616161616161616161616161616161616161616161"),
|
||||
(0, util_hex_encoding_1.fromHex)("a27c896c4859204843166af66f0e902b9c3b3ed6d2fd13d435abc020065c526f")
|
||||
],
|
||||
[
|
||||
(0, util_hex_encoding_1.fromHex)("6161616161616161616161616161616161616161616161616161616161616161616161"),
|
||||
(0, util_hex_encoding_1.fromHex)("629362afc62c74497caed2272e30f8125ecd0965f8d8d7cfc4e260f7f8dd319d")
|
||||
],
|
||||
[
|
||||
(0, util_hex_encoding_1.fromHex)("616161616161616161616161616161616161616161616161616161616161616161616161"),
|
||||
(0, util_hex_encoding_1.fromHex)("22c1d24bcd03e9aee9832efccd6da613fc702793178e5f12c945c7b67ddda933")
|
||||
],
|
||||
[
|
||||
(0, util_hex_encoding_1.fromHex)("61616161616161616161616161616161616161616161616161616161616161616161616161"),
|
||||
(0, util_hex_encoding_1.fromHex)("21ec055b38ce759cd4d0f477e9bdec2c5b8199945db4439bae334a964df6246c")
|
||||
],
|
||||
[
|
||||
(0, util_hex_encoding_1.fromHex)("6161616161616161616161616161616161616161616161616161616161616161616161616161"),
|
||||
(0, util_hex_encoding_1.fromHex)("365a9c3e2c2af0a56e47a9dac51c2c5381bf8f41273bad3175e0e619126ad087")
|
||||
],
|
||||
[
|
||||
(0, util_hex_encoding_1.fromHex)("616161616161616161616161616161616161616161616161616161616161616161616161616161"),
|
||||
(0, util_hex_encoding_1.fromHex)("b4d5e56e929ba4cda349e9274e3603d0be246b82016bca20f363963c5f2d6845")
|
||||
],
|
||||
[
|
||||
(0, util_hex_encoding_1.fromHex)("61616161616161616161616161616161616161616161616161616161616161616161616161616161"),
|
||||
(0, util_hex_encoding_1.fromHex)("e33cdf9c7f7120b98e8c78408953e07f2ecd183006b5606df349b4c212acf43e")
|
||||
],
|
||||
[
|
||||
(0, util_hex_encoding_1.fromHex)("6161616161616161616161616161616161616161616161616161616161616161616161616161616161"),
|
||||
(0, util_hex_encoding_1.fromHex)("c0f8bd4dbc2b0c03107c1c37913f2a7501f521467f45dd0fef6958e9a4692719")
|
||||
],
|
||||
[
|
||||
(0, util_hex_encoding_1.fromHex)("616161616161616161616161616161616161616161616161616161616161616161616161616161616161"),
|
||||
(0, util_hex_encoding_1.fromHex)("7a538607fdaab9296995929f451565bbb8142e1844117322aafd2b3d76b01aff")
|
||||
],
|
||||
[
|
||||
(0, util_hex_encoding_1.fromHex)("61616161616161616161616161616161616161616161616161616161616161616161616161616161616161"),
|
||||
(0, util_hex_encoding_1.fromHex)("66d34fba71f8f450f7e45598853e53bfc23bbd129027cbb131a2f4ffd7878cd0")
|
||||
],
|
||||
[
|
||||
(0, util_hex_encoding_1.fromHex)("6161616161616161616161616161616161616161616161616161616161616161616161616161616161616161"),
|
||||
(0, util_hex_encoding_1.fromHex)("16849877c6c21ef0bfa68e4f6747300ddb171b170b9f00e189edc4c2fc4db93e")
|
||||
],
|
||||
[
|
||||
(0, util_hex_encoding_1.fromHex)("616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161"),
|
||||
(0, util_hex_encoding_1.fromHex)("52789e3423b72beeb898456a4f49662e46b0cbb960784c5ef4b1399d327e7c27")
|
||||
],
|
||||
[
|
||||
(0, util_hex_encoding_1.fromHex)("61616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161"),
|
||||
(0, util_hex_encoding_1.fromHex)("6643110c5628fff59edf76d82d5bf573bf800f16a4d65dfb1e5d6f1a46296d0b")
|
||||
],
|
||||
[
|
||||
(0, util_hex_encoding_1.fromHex)("6161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161"),
|
||||
(0, util_hex_encoding_1.fromHex)("11eaed932c6c6fddfc2efc394e609facf4abe814fc6180d03b14fce13a07d0e5")
|
||||
],
|
||||
[
|
||||
(0, util_hex_encoding_1.fromHex)("616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161"),
|
||||
(0, util_hex_encoding_1.fromHex)("97daac0ee9998dfcad6c9c0970da5ca411c86233a944c25b47566f6a7bc1ddd5")
|
||||
],
|
||||
[
|
||||
(0, util_hex_encoding_1.fromHex)("61616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161"),
|
||||
(0, util_hex_encoding_1.fromHex)("8f9bec6a62dd28ebd36d1227745592de6658b36974a3bb98a4c582f683ea6c42")
|
||||
],
|
||||
[
|
||||
(0, util_hex_encoding_1.fromHex)("6161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161"),
|
||||
(0, util_hex_encoding_1.fromHex)("160b4e433e384e05e537dc59b467f7cb2403f0214db15c5db58862a3f1156d2e")
|
||||
],
|
||||
[
|
||||
(0, util_hex_encoding_1.fromHex)("616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161"),
|
||||
(0, util_hex_encoding_1.fromHex)("bfc5fe0e360152ca98c50fab4ed7e3078c17debc2917740d5000913b686ca129")
|
||||
],
|
||||
[
|
||||
(0, util_hex_encoding_1.fromHex)("61616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161"),
|
||||
(0, util_hex_encoding_1.fromHex)("6c1b3dc7a706b9dc81352a6716b9c666c608d8626272c64b914ab05572fc6e84")
|
||||
],
|
||||
[
|
||||
(0, util_hex_encoding_1.fromHex)("6161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161"),
|
||||
(0, util_hex_encoding_1.fromHex)("abe346a7259fc90b4c27185419628e5e6af6466b1ae9b5446cac4bfc26cf05c4")
|
||||
],
|
||||
[
|
||||
(0, util_hex_encoding_1.fromHex)("616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161"),
|
||||
(0, util_hex_encoding_1.fromHex)("a3f01b6939256127582ac8ae9fb47a382a244680806a3f613a118851c1ca1d47")
|
||||
],
|
||||
[
|
||||
(0, util_hex_encoding_1.fromHex)("61616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161"),
|
||||
(0, util_hex_encoding_1.fromHex)("9f4390f8d30c2dd92ec9f095b65e2b9ae9b0a925a5258e241c9f1e910f734318")
|
||||
],
|
||||
[
|
||||
(0, util_hex_encoding_1.fromHex)("6161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161"),
|
||||
(0, util_hex_encoding_1.fromHex)("b35439a4ac6f0948b6d6f9e3c6af0f5f590ce20f1bde7090ef7970686ec6738a")
|
||||
],
|
||||
[
|
||||
(0, util_hex_encoding_1.fromHex)("616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161"),
|
||||
(0, util_hex_encoding_1.fromHex)("f13b2d724659eb3bf47f2dd6af1accc87b81f09f59f2b75e5c0bed6589dfe8c6")
|
||||
],
|
||||
[
|
||||
(0, util_hex_encoding_1.fromHex)("61616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161"),
|
||||
(0, util_hex_encoding_1.fromHex)("d5c039b748aa64665782974ec3dc3025c042edf54dcdc2b5de31385b094cb678")
|
||||
],
|
||||
[
|
||||
(0, util_hex_encoding_1.fromHex)("6161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161"),
|
||||
(0, util_hex_encoding_1.fromHex)("111bb261277afd65f0744b247cd3e47d386d71563d0ed995517807d5ebd4fba3")
|
||||
],
|
||||
[
|
||||
(0, util_hex_encoding_1.fromHex)("616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161"),
|
||||
(0, util_hex_encoding_1.fromHex)("11ee391211c6256460b6ed375957fadd8061cafbb31daf967db875aebd5aaad4")
|
||||
],
|
||||
[
|
||||
(0, util_hex_encoding_1.fromHex)("61616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161"),
|
||||
(0, util_hex_encoding_1.fromHex)("35d5fc17cfbbadd00f5e710ada39f194c5ad7c766ad67072245f1fad45f0f530")
|
||||
],
|
||||
[
|
||||
(0, util_hex_encoding_1.fromHex)("6161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161"),
|
||||
(0, util_hex_encoding_1.fromHex)("f506898cc7c2e092f9eb9fadae7ba50383f5b46a2a4fe5597dbb553a78981268")
|
||||
],
|
||||
[
|
||||
(0, util_hex_encoding_1.fromHex)("616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161"),
|
||||
(0, util_hex_encoding_1.fromHex)("7d3e74a05d7db15bce4ad9ec0658ea98e3f06eeecf16b4c6fff2da457ddc2f34")
|
||||
],
|
||||
[
|
||||
(0, util_hex_encoding_1.fromHex)("61616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161"),
|
||||
(0, util_hex_encoding_1.fromHex)("ffe054fe7ae0cb6dc65c3af9b61d5209f439851db43d0ba5997337df154668eb")
|
||||
],
|
||||
[
|
||||
(0, util_hex_encoding_1.fromHex)("de188941a3375d3a8a061e67576e926dc71a7fa3f0cceb97452b4d3227965f9ea8cc75076d9fb9c5417aa5cb30fc22198b34982dbb629e"),
|
||||
(0, util_hex_encoding_1.fromHex)("038051e9c324393bd1ca1978dd0952c2aa3742ca4f1bd5cd4611cea83892d382")
|
||||
],
|
||||
[
|
||||
millionChars,
|
||||
(0, util_hex_encoding_1.fromHex)("cdc76e5c9914fb9281a1c7e284d73e67f1809a48a497200e046d39ccc7112cd0")
|
||||
],
|
||||
[
|
||||
(0, util_hex_encoding_1.fromHex)("aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa"),
|
||||
(0, util_hex_encoding_1.fromHex)("45ad4b37c6e2fc0a2cfcc1b5da524132ec707615c2cae1dbbc43c97aa521db81")
|
||||
]
|
||||
];
|
||||
/**
|
||||
* @see https://tools.ietf.org/html/rfc4231
|
||||
*/
|
||||
exports.hmacTestVectors = [
|
||||
[
|
||||
(0, util_hex_encoding_1.fromHex)("0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b"),
|
||||
(0, util_hex_encoding_1.fromHex)("4869205468657265"),
|
||||
(0, util_hex_encoding_1.fromHex)("b0344c61d8db38535ca8afceaf0bf12b881dc200c9833da726e9376c2e32cff7")
|
||||
],
|
||||
[
|
||||
(0, util_hex_encoding_1.fromHex)("4a656665"),
|
||||
(0, util_hex_encoding_1.fromHex)("7768617420646f2079612077616e7420666f72206e6f7468696e673f"),
|
||||
(0, util_hex_encoding_1.fromHex)("5bdcc146bf60754e6a042426089575c75a003f089d2739839dec58b964ec3843")
|
||||
],
|
||||
[
|
||||
(0, util_hex_encoding_1.fromHex)("aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa"),
|
||||
(0, util_hex_encoding_1.fromHex)("dddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddd"),
|
||||
(0, util_hex_encoding_1.fromHex)("773ea91e36800e46854db8ebd09181a72959098b3ef8c122d9635514ced565fe")
|
||||
],
|
||||
[
|
||||
(0, util_hex_encoding_1.fromHex)("0102030405060708090a0b0c0d0e0f10111213141516171819"),
|
||||
(0, util_hex_encoding_1.fromHex)("cdcdcdcdcdcdcdcdcdcdcdcdcdcdcdcdcdcdcdcdcdcdcdcdcdcdcdcdcdcdcdcdcdcdcdcdcdcdcdcdcdcdcdcdcdcdcdcdcdcd"),
|
||||
(0, util_hex_encoding_1.fromHex)("82558a389a443c0ea4cc819899f2083a85f0faa3e578f8077a2e3ff46729665b")
|
||||
],
|
||||
[
|
||||
(0, util_hex_encoding_1.fromHex)("aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa"),
|
||||
(0, util_hex_encoding_1.fromHex)("54657374205573696e67204c6172676572205468616e20426c6f636b2d53697a65204b6579202d2048617368204b6579204669727374"),
|
||||
(0, util_hex_encoding_1.fromHex)("60e431591ee0b67f0d8a26aacbf5b77f8e0bc6213728c5140546040f0ee37f54")
|
||||
],
|
||||
[
|
||||
(0, util_hex_encoding_1.fromHex)("aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa"),
|
||||
(0, util_hex_encoding_1.fromHex)("5468697320697320612074657374207573696e672061206c6172676572207468616e20626c6f636b2d73697a65206b657920616e642061206c6172676572207468616e20626c6f636b2d73697a6520646174612e20546865206b6579206e6565647320746f20626520686173686564206265666f7265206265696e6720757365642062792074686520484d414320616c676f726974686d2e"),
|
||||
(0, util_hex_encoding_1.fromHex)("9b09ffa71b942fcb27635fbcd5b0e944bfdc63644f0713938a7f51535c3a35e2")
|
||||
]
|
||||
];
|
||||
//# sourceMappingURL=knownHashes.fixture.js.map
|
||||
1
backend/node_modules/@aws-crypto/sha256-js/build/main/knownHashes.fixture.js.map
generated
vendored
Normal file
1
backend/node_modules/@aws-crypto/sha256-js/build/main/knownHashes.fixture.js.map
generated
vendored
Normal file
File diff suppressed because one or more lines are too long
17
backend/node_modules/@aws-crypto/sha256-js/build/module/RawSha256.d.ts
generated
vendored
Normal file
17
backend/node_modules/@aws-crypto/sha256-js/build/module/RawSha256.d.ts
generated
vendored
Normal file
@@ -0,0 +1,17 @@
|
||||
/**
|
||||
* @internal
|
||||
*/
|
||||
export declare class RawSha256 {
|
||||
private state;
|
||||
private temp;
|
||||
private buffer;
|
||||
private bufferLength;
|
||||
private bytesHashed;
|
||||
/**
|
||||
* @internal
|
||||
*/
|
||||
finished: boolean;
|
||||
update(data: Uint8Array): void;
|
||||
digest(): Uint8Array;
|
||||
private hashBuffer;
|
||||
}
|
||||
121
backend/node_modules/@aws-crypto/sha256-js/build/module/RawSha256.js
generated
vendored
Normal file
121
backend/node_modules/@aws-crypto/sha256-js/build/module/RawSha256.js
generated
vendored
Normal file
@@ -0,0 +1,121 @@
|
||||
import { BLOCK_SIZE, DIGEST_LENGTH, INIT, KEY, MAX_HASHABLE_LENGTH } from "./constants";
|
||||
/**
|
||||
* @internal
|
||||
*/
|
||||
var RawSha256 = /** @class */ (function () {
|
||||
function RawSha256() {
|
||||
this.state = Int32Array.from(INIT);
|
||||
this.temp = new Int32Array(64);
|
||||
this.buffer = new Uint8Array(64);
|
||||
this.bufferLength = 0;
|
||||
this.bytesHashed = 0;
|
||||
/**
|
||||
* @internal
|
||||
*/
|
||||
this.finished = false;
|
||||
}
|
||||
RawSha256.prototype.update = function (data) {
|
||||
if (this.finished) {
|
||||
throw new Error("Attempted to update an already finished hash.");
|
||||
}
|
||||
var position = 0;
|
||||
var byteLength = data.byteLength;
|
||||
this.bytesHashed += byteLength;
|
||||
if (this.bytesHashed * 8 > MAX_HASHABLE_LENGTH) {
|
||||
throw new Error("Cannot hash more than 2^53 - 1 bits");
|
||||
}
|
||||
while (byteLength > 0) {
|
||||
this.buffer[this.bufferLength++] = data[position++];
|
||||
byteLength--;
|
||||
if (this.bufferLength === BLOCK_SIZE) {
|
||||
this.hashBuffer();
|
||||
this.bufferLength = 0;
|
||||
}
|
||||
}
|
||||
};
|
||||
RawSha256.prototype.digest = function () {
|
||||
if (!this.finished) {
|
||||
var bitsHashed = this.bytesHashed * 8;
|
||||
var bufferView = new DataView(this.buffer.buffer, this.buffer.byteOffset, this.buffer.byteLength);
|
||||
var undecoratedLength = this.bufferLength;
|
||||
bufferView.setUint8(this.bufferLength++, 0x80);
|
||||
// Ensure the final block has enough room for the hashed length
|
||||
if (undecoratedLength % BLOCK_SIZE >= BLOCK_SIZE - 8) {
|
||||
for (var i = this.bufferLength; i < BLOCK_SIZE; i++) {
|
||||
bufferView.setUint8(i, 0);
|
||||
}
|
||||
this.hashBuffer();
|
||||
this.bufferLength = 0;
|
||||
}
|
||||
for (var i = this.bufferLength; i < BLOCK_SIZE - 8; i++) {
|
||||
bufferView.setUint8(i, 0);
|
||||
}
|
||||
bufferView.setUint32(BLOCK_SIZE - 8, Math.floor(bitsHashed / 0x100000000), true);
|
||||
bufferView.setUint32(BLOCK_SIZE - 4, bitsHashed);
|
||||
this.hashBuffer();
|
||||
this.finished = true;
|
||||
}
|
||||
// The value in state is little-endian rather than big-endian, so flip
|
||||
// each word into a new Uint8Array
|
||||
var out = new Uint8Array(DIGEST_LENGTH);
|
||||
for (var i = 0; i < 8; i++) {
|
||||
out[i * 4] = (this.state[i] >>> 24) & 0xff;
|
||||
out[i * 4 + 1] = (this.state[i] >>> 16) & 0xff;
|
||||
out[i * 4 + 2] = (this.state[i] >>> 8) & 0xff;
|
||||
out[i * 4 + 3] = (this.state[i] >>> 0) & 0xff;
|
||||
}
|
||||
return out;
|
||||
};
|
||||
RawSha256.prototype.hashBuffer = function () {
|
||||
var _a = this, buffer = _a.buffer, state = _a.state;
|
||||
var state0 = state[0], state1 = state[1], state2 = state[2], state3 = state[3], state4 = state[4], state5 = state[5], state6 = state[6], state7 = state[7];
|
||||
for (var i = 0; i < BLOCK_SIZE; i++) {
|
||||
if (i < 16) {
|
||||
this.temp[i] =
|
||||
((buffer[i * 4] & 0xff) << 24) |
|
||||
((buffer[i * 4 + 1] & 0xff) << 16) |
|
||||
((buffer[i * 4 + 2] & 0xff) << 8) |
|
||||
(buffer[i * 4 + 3] & 0xff);
|
||||
}
|
||||
else {
|
||||
var u = this.temp[i - 2];
|
||||
var t1_1 = ((u >>> 17) | (u << 15)) ^ ((u >>> 19) | (u << 13)) ^ (u >>> 10);
|
||||
u = this.temp[i - 15];
|
||||
var t2_1 = ((u >>> 7) | (u << 25)) ^ ((u >>> 18) | (u << 14)) ^ (u >>> 3);
|
||||
this.temp[i] =
|
||||
((t1_1 + this.temp[i - 7]) | 0) + ((t2_1 + this.temp[i - 16]) | 0);
|
||||
}
|
||||
var t1 = ((((((state4 >>> 6) | (state4 << 26)) ^
|
||||
((state4 >>> 11) | (state4 << 21)) ^
|
||||
((state4 >>> 25) | (state4 << 7))) +
|
||||
((state4 & state5) ^ (~state4 & state6))) |
|
||||
0) +
|
||||
((state7 + ((KEY[i] + this.temp[i]) | 0)) | 0)) |
|
||||
0;
|
||||
var t2 = ((((state0 >>> 2) | (state0 << 30)) ^
|
||||
((state0 >>> 13) | (state0 << 19)) ^
|
||||
((state0 >>> 22) | (state0 << 10))) +
|
||||
((state0 & state1) ^ (state0 & state2) ^ (state1 & state2))) |
|
||||
0;
|
||||
state7 = state6;
|
||||
state6 = state5;
|
||||
state5 = state4;
|
||||
state4 = (state3 + t1) | 0;
|
||||
state3 = state2;
|
||||
state2 = state1;
|
||||
state1 = state0;
|
||||
state0 = (t1 + t2) | 0;
|
||||
}
|
||||
state[0] += state0;
|
||||
state[1] += state1;
|
||||
state[2] += state2;
|
||||
state[3] += state3;
|
||||
state[4] += state4;
|
||||
state[5] += state5;
|
||||
state[6] += state6;
|
||||
state[7] += state7;
|
||||
};
|
||||
return RawSha256;
|
||||
}());
|
||||
export { RawSha256 };
|
||||
//# sourceMappingURL=RawSha256.js.map
|
||||
1
backend/node_modules/@aws-crypto/sha256-js/build/module/RawSha256.js.map
generated
vendored
Normal file
1
backend/node_modules/@aws-crypto/sha256-js/build/module/RawSha256.js.map
generated
vendored
Normal file
File diff suppressed because one or more lines are too long
20
backend/node_modules/@aws-crypto/sha256-js/build/module/constants.d.ts
generated
vendored
Normal file
20
backend/node_modules/@aws-crypto/sha256-js/build/module/constants.d.ts
generated
vendored
Normal file
@@ -0,0 +1,20 @@
|
||||
/**
|
||||
* @internal
|
||||
*/
|
||||
export declare const BLOCK_SIZE: number;
|
||||
/**
|
||||
* @internal
|
||||
*/
|
||||
export declare const DIGEST_LENGTH: number;
|
||||
/**
|
||||
* @internal
|
||||
*/
|
||||
export declare const KEY: Uint32Array;
|
||||
/**
|
||||
* @internal
|
||||
*/
|
||||
export declare const INIT: number[];
|
||||
/**
|
||||
* @internal
|
||||
*/
|
||||
export declare const MAX_HASHABLE_LENGTH: number;
|
||||
95
backend/node_modules/@aws-crypto/sha256-js/build/module/constants.js
generated
vendored
Normal file
95
backend/node_modules/@aws-crypto/sha256-js/build/module/constants.js
generated
vendored
Normal file
@@ -0,0 +1,95 @@
|
||||
/**
|
||||
* @internal
|
||||
*/
|
||||
export var BLOCK_SIZE = 64;
|
||||
/**
|
||||
* @internal
|
||||
*/
|
||||
export var DIGEST_LENGTH = 32;
|
||||
/**
|
||||
* @internal
|
||||
*/
|
||||
export var KEY = new Uint32Array([
|
||||
0x428a2f98,
|
||||
0x71374491,
|
||||
0xb5c0fbcf,
|
||||
0xe9b5dba5,
|
||||
0x3956c25b,
|
||||
0x59f111f1,
|
||||
0x923f82a4,
|
||||
0xab1c5ed5,
|
||||
0xd807aa98,
|
||||
0x12835b01,
|
||||
0x243185be,
|
||||
0x550c7dc3,
|
||||
0x72be5d74,
|
||||
0x80deb1fe,
|
||||
0x9bdc06a7,
|
||||
0xc19bf174,
|
||||
0xe49b69c1,
|
||||
0xefbe4786,
|
||||
0x0fc19dc6,
|
||||
0x240ca1cc,
|
||||
0x2de92c6f,
|
||||
0x4a7484aa,
|
||||
0x5cb0a9dc,
|
||||
0x76f988da,
|
||||
0x983e5152,
|
||||
0xa831c66d,
|
||||
0xb00327c8,
|
||||
0xbf597fc7,
|
||||
0xc6e00bf3,
|
||||
0xd5a79147,
|
||||
0x06ca6351,
|
||||
0x14292967,
|
||||
0x27b70a85,
|
||||
0x2e1b2138,
|
||||
0x4d2c6dfc,
|
||||
0x53380d13,
|
||||
0x650a7354,
|
||||
0x766a0abb,
|
||||
0x81c2c92e,
|
||||
0x92722c85,
|
||||
0xa2bfe8a1,
|
||||
0xa81a664b,
|
||||
0xc24b8b70,
|
||||
0xc76c51a3,
|
||||
0xd192e819,
|
||||
0xd6990624,
|
||||
0xf40e3585,
|
||||
0x106aa070,
|
||||
0x19a4c116,
|
||||
0x1e376c08,
|
||||
0x2748774c,
|
||||
0x34b0bcb5,
|
||||
0x391c0cb3,
|
||||
0x4ed8aa4a,
|
||||
0x5b9cca4f,
|
||||
0x682e6ff3,
|
||||
0x748f82ee,
|
||||
0x78a5636f,
|
||||
0x84c87814,
|
||||
0x8cc70208,
|
||||
0x90befffa,
|
||||
0xa4506ceb,
|
||||
0xbef9a3f7,
|
||||
0xc67178f2
|
||||
]);
|
||||
/**
|
||||
* @internal
|
||||
*/
|
||||
export var INIT = [
|
||||
0x6a09e667,
|
||||
0xbb67ae85,
|
||||
0x3c6ef372,
|
||||
0xa54ff53a,
|
||||
0x510e527f,
|
||||
0x9b05688c,
|
||||
0x1f83d9ab,
|
||||
0x5be0cd19
|
||||
];
|
||||
/**
|
||||
* @internal
|
||||
*/
|
||||
export var MAX_HASHABLE_LENGTH = Math.pow(2, 53) - 1;
|
||||
//# sourceMappingURL=constants.js.map
|
||||
1
backend/node_modules/@aws-crypto/sha256-js/build/module/constants.js.map
generated
vendored
Normal file
1
backend/node_modules/@aws-crypto/sha256-js/build/module/constants.js.map
generated
vendored
Normal file
@@ -0,0 +1 @@
|
||||
{"version":3,"file":"constants.js","sourceRoot":"","sources":["../../src/constants.ts"],"names":[],"mappings":"AAAA;;GAEG;AACH,MAAM,CAAC,IAAM,UAAU,GAAW,EAAE,CAAC;AAErC;;GAEG;AACH,MAAM,CAAC,IAAM,aAAa,GAAW,EAAE,CAAC;AAExC;;GAEG;AACH,MAAM,CAAC,IAAM,GAAG,GAAG,IAAI,WAAW,CAAC;IACjC,UAAU;IACV,UAAU;IACV,UAAU;IACV,UAAU;IACV,UAAU;IACV,UAAU;IACV,UAAU;IACV,UAAU;IACV,UAAU;IACV,UAAU;IACV,UAAU;IACV,UAAU;IACV,UAAU;IACV,UAAU;IACV,UAAU;IACV,UAAU;IACV,UAAU;IACV,UAAU;IACV,UAAU;IACV,UAAU;IACV,UAAU;IACV,UAAU;IACV,UAAU;IACV,UAAU;IACV,UAAU;IACV,UAAU;IACV,UAAU;IACV,UAAU;IACV,UAAU;IACV,UAAU;IACV,UAAU;IACV,UAAU;IACV,UAAU;IACV,UAAU;IACV,UAAU;IACV,UAAU;IACV,UAAU;IACV,UAAU;IACV,UAAU;IACV,UAAU;IACV,UAAU;IACV,UAAU;IACV,UAAU;IACV,UAAU;IACV,UAAU;IACV,UAAU;IACV,UAAU;IACV,UAAU;IACV,UAAU;IACV,UAAU;IACV,UAAU;IACV,UAAU;IACV,UAAU;IACV,UAAU;IACV,UAAU;IACV,UAAU;IACV,UAAU;IACV,UAAU;IACV,UAAU;IACV,UAAU;IACV,UAAU;IACV,UAAU;IACV,UAAU;IACV,UAAU;CACX,CAAC,CAAC;AAEH;;GAEG;AACH,MAAM,CAAC,IAAM,IAAI,GAAG;IAClB,UAAU;IACV,UAAU;IACV,UAAU;IACV,UAAU;IACV,UAAU;IACV,UAAU;IACV,UAAU;IACV,UAAU;CACX,CAAC;AAEF;;GAEG;AACH,MAAM,CAAC,IAAM,mBAAmB,GAAG,SAAA,CAAC,EAAI,EAAE,CAAA,GAAG,CAAC,CAAC"}
|
||||
1
backend/node_modules/@aws-crypto/sha256-js/build/module/index.d.ts
generated
vendored
Normal file
1
backend/node_modules/@aws-crypto/sha256-js/build/module/index.d.ts
generated
vendored
Normal file
@@ -0,0 +1 @@
|
||||
export * from "./jsSha256";
|
||||
2
backend/node_modules/@aws-crypto/sha256-js/build/module/index.js
generated
vendored
Normal file
2
backend/node_modules/@aws-crypto/sha256-js/build/module/index.js
generated
vendored
Normal file
@@ -0,0 +1,2 @@
|
||||
export * from "./jsSha256";
|
||||
//# sourceMappingURL=index.js.map
|
||||
1
backend/node_modules/@aws-crypto/sha256-js/build/module/index.js.map
generated
vendored
Normal file
1
backend/node_modules/@aws-crypto/sha256-js/build/module/index.js.map
generated
vendored
Normal file
@@ -0,0 +1 @@
|
||||
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/index.ts"],"names":[],"mappings":"AAAA,cAAc,YAAY,CAAC"}
|
||||
12
backend/node_modules/@aws-crypto/sha256-js/build/module/jsSha256.d.ts
generated
vendored
Normal file
12
backend/node_modules/@aws-crypto/sha256-js/build/module/jsSha256.d.ts
generated
vendored
Normal file
@@ -0,0 +1,12 @@
|
||||
import { Checksum, SourceData } from "@aws-sdk/types";
|
||||
export declare class Sha256 implements Checksum {
|
||||
private readonly secret?;
|
||||
private hash;
|
||||
private outer?;
|
||||
private error;
|
||||
constructor(secret?: SourceData);
|
||||
update(toHash: SourceData): void;
|
||||
digestSync(): Uint8Array;
|
||||
digest(): Promise<Uint8Array>;
|
||||
reset(): void;
|
||||
}
|
||||
82
backend/node_modules/@aws-crypto/sha256-js/build/module/jsSha256.js
generated
vendored
Normal file
82
backend/node_modules/@aws-crypto/sha256-js/build/module/jsSha256.js
generated
vendored
Normal file
@@ -0,0 +1,82 @@
|
||||
import { __awaiter, __generator } from "tslib";
|
||||
import { BLOCK_SIZE } from "./constants";
|
||||
import { RawSha256 } from "./RawSha256";
|
||||
import { isEmptyData, convertToBuffer } from "@aws-crypto/util";
|
||||
var Sha256 = /** @class */ (function () {
|
||||
function Sha256(secret) {
|
||||
this.secret = secret;
|
||||
this.hash = new RawSha256();
|
||||
this.reset();
|
||||
}
|
||||
Sha256.prototype.update = function (toHash) {
|
||||
if (isEmptyData(toHash) || this.error) {
|
||||
return;
|
||||
}
|
||||
try {
|
||||
this.hash.update(convertToBuffer(toHash));
|
||||
}
|
||||
catch (e) {
|
||||
this.error = e;
|
||||
}
|
||||
};
|
||||
/* This synchronous method keeps compatibility
|
||||
* with the v2 aws-sdk.
|
||||
*/
|
||||
Sha256.prototype.digestSync = function () {
|
||||
if (this.error) {
|
||||
throw this.error;
|
||||
}
|
||||
if (this.outer) {
|
||||
if (!this.outer.finished) {
|
||||
this.outer.update(this.hash.digest());
|
||||
}
|
||||
return this.outer.digest();
|
||||
}
|
||||
return this.hash.digest();
|
||||
};
|
||||
/* The underlying digest method here is synchronous.
|
||||
* To keep the same interface with the other hash functions
|
||||
* the default is to expose this as an async method.
|
||||
* However, it can sometimes be useful to have a sync method.
|
||||
*/
|
||||
Sha256.prototype.digest = function () {
|
||||
return __awaiter(this, void 0, void 0, function () {
|
||||
return __generator(this, function (_a) {
|
||||
return [2 /*return*/, this.digestSync()];
|
||||
});
|
||||
});
|
||||
};
|
||||
Sha256.prototype.reset = function () {
|
||||
this.hash = new RawSha256();
|
||||
if (this.secret) {
|
||||
this.outer = new RawSha256();
|
||||
var inner = bufferFromSecret(this.secret);
|
||||
var outer = new Uint8Array(BLOCK_SIZE);
|
||||
outer.set(inner);
|
||||
for (var i = 0; i < BLOCK_SIZE; i++) {
|
||||
inner[i] ^= 0x36;
|
||||
outer[i] ^= 0x5c;
|
||||
}
|
||||
this.hash.update(inner);
|
||||
this.outer.update(outer);
|
||||
// overwrite the copied key in memory
|
||||
for (var i = 0; i < inner.byteLength; i++) {
|
||||
inner[i] = 0;
|
||||
}
|
||||
}
|
||||
};
|
||||
return Sha256;
|
||||
}());
|
||||
export { Sha256 };
|
||||
function bufferFromSecret(secret) {
|
||||
var input = convertToBuffer(secret);
|
||||
if (input.byteLength > BLOCK_SIZE) {
|
||||
var bufferHash = new RawSha256();
|
||||
bufferHash.update(input);
|
||||
input = bufferHash.digest();
|
||||
}
|
||||
var buffer = new Uint8Array(BLOCK_SIZE);
|
||||
buffer.set(input);
|
||||
return buffer;
|
||||
}
|
||||
//# sourceMappingURL=jsSha256.js.map
|
||||
1
backend/node_modules/@aws-crypto/sha256-js/build/module/jsSha256.js.map
generated
vendored
Normal file
1
backend/node_modules/@aws-crypto/sha256-js/build/module/jsSha256.js.map
generated
vendored
Normal file
@@ -0,0 +1 @@
|
||||
{"version":3,"file":"jsSha256.js","sourceRoot":"","sources":["../../src/jsSha256.ts"],"names":[],"mappings":";AAAA,OAAO,EAAE,UAAU,EAAE,MAAM,aAAa,CAAC;AACzC,OAAO,EAAE,SAAS,EAAE,MAAM,aAAa,CAAC;AAExC,OAAO,EAAE,WAAW,EAAE,eAAe,EAAE,MAAM,kBAAkB,CAAC;AAEhE;IAME,gBAAY,MAAmB;QAC7B,IAAI,CAAC,MAAM,GAAG,MAAM,CAAC;QACrB,IAAI,CAAC,IAAI,GAAG,IAAI,SAAS,EAAE,CAAC;QAC5B,IAAI,CAAC,KAAK,EAAE,CAAC;IACf,CAAC;IAED,uBAAM,GAAN,UAAO,MAAkB;QACvB,IAAI,WAAW,CAAC,MAAM,CAAC,IAAI,IAAI,CAAC,KAAK,EAAE;YACrC,OAAO;SACR;QAED,IAAI;YACF,IAAI,CAAC,IAAI,CAAC,MAAM,CAAC,eAAe,CAAC,MAAM,CAAC,CAAC,CAAC;SAC3C;QAAC,OAAO,CAAC,EAAE;YACV,IAAI,CAAC,KAAK,GAAG,CAAC,CAAC;SAChB;IACH,CAAC;IAED;;OAEG;IACH,2BAAU,GAAV;QACE,IAAI,IAAI,CAAC,KAAK,EAAE;YACd,MAAM,IAAI,CAAC,KAAK,CAAC;SAClB;QAED,IAAI,IAAI,CAAC,KAAK,EAAE;YACd,IAAI,CAAC,IAAI,CAAC,KAAK,CAAC,QAAQ,EAAE;gBACxB,IAAI,CAAC,KAAK,CAAC,MAAM,CAAC,IAAI,CAAC,IAAI,CAAC,MAAM,EAAE,CAAC,CAAC;aACvC;YAED,OAAO,IAAI,CAAC,KAAK,CAAC,MAAM,EAAE,CAAC;SAC5B;QAED,OAAO,IAAI,CAAC,IAAI,CAAC,MAAM,EAAE,CAAC;IAC5B,CAAC;IAED;;;;OAIG;IACG,uBAAM,GAAZ;;;gBACE,sBAAO,IAAI,CAAC,UAAU,EAAE,EAAC;;;KAC1B;IAED,sBAAK,GAAL;QACE,IAAI,CAAC,IAAI,GAAG,IAAI,SAAS,EAAE,CAAC;QAC5B,IAAI,IAAI,CAAC,MAAM,EAAE;YACf,IAAI,CAAC,KAAK,GAAG,IAAI,SAAS,EAAE,CAAC;YAC7B,IAAM,KAAK,GAAG,gBAAgB,CAAC,IAAI,CAAC,MAAM,CAAC,CAAC;YAC5C,IAAM,KAAK,GAAG,IAAI,UAAU,CAAC,UAAU,CAAC,CAAC;YACzC,KAAK,CAAC,GAAG,CAAC,KAAK,CAAC,CAAC;YAEjB,KAAK,IAAI,CAAC,GAAG,CAAC,EAAE,CAAC,GAAG,UAAU,EAAE,CAAC,EAAE,EAAE;gBACnC,KAAK,CAAC,CAAC,CAAC,IAAI,IAAI,CAAC;gBACjB,KAAK,CAAC,CAAC,CAAC,IAAI,IAAI,CAAC;aAClB;YAED,IAAI,CAAC,IAAI,CAAC,MAAM,CAAC,KAAK,CAAC,CAAC;YACxB,IAAI,CAAC,KAAK,CAAC,MAAM,CAAC,KAAK,CAAC,CAAC;YAEzB,qCAAqC;YACrC,KAAK,IAAI,CAAC,GAAG,CAAC,EAAE,CAAC,GAAG,KAAK,CAAC,UAAU,EAAE,CAAC,EAAE,EAAE;gBACzC,KAAK,CAAC,CAAC,CAAC,GAAG,CAAC,CAAC;aACd;SACF;IACH,CAAC;IACH,aAAC;AAAD,CAAC,AA1ED,IA0EC;;AAED,SAAS,gBAAgB,CAAC,MAAkB;IAC1C,IAAI,KAAK,GAAG,eAAe,CAAC,MAAM,CAAC,CAAC;IAEpC,IAAI,KAAK,CAAC,UAAU,GAAG,UAAU,EAAE;QACjC,IAAM,UAAU,GAAG,IAAI,SAAS,EAAE,CAAC;QACnC,UAAU,CAAC,MAAM,CAAC,KAAK,CAAC,CAAC;QACzB,KAAK,GAAG,UAAU,CAAC,MAAM,EAAE,CAAC;KAC7B;IAED,IAAM,MAAM,GAAG,IAAI,UAAU,CAAC,UAAU,CAAC,CAAC;IAC1C,MAAM,CAAC,GAAG,CAAC,KAAK,CAAC,CAAC;IAClB,OAAO,MAAM,CAAC;AAChB,CAAC"}
|
||||
5
backend/node_modules/@aws-crypto/sha256-js/build/module/knownHashes.fixture.d.ts
generated
vendored
Normal file
5
backend/node_modules/@aws-crypto/sha256-js/build/module/knownHashes.fixture.d.ts
generated
vendored
Normal file
@@ -0,0 +1,5 @@
|
||||
export declare const hashTestVectors: Array<[Uint8Array, Uint8Array]>;
|
||||
/**
|
||||
* @see https://tools.ietf.org/html/rfc4231
|
||||
*/
|
||||
export declare const hmacTestVectors: Array<[Uint8Array, Uint8Array, Uint8Array]>;
|
||||
319
backend/node_modules/@aws-crypto/sha256-js/build/module/knownHashes.fixture.js
generated
vendored
Normal file
319
backend/node_modules/@aws-crypto/sha256-js/build/module/knownHashes.fixture.js
generated
vendored
Normal file
@@ -0,0 +1,319 @@
|
||||
import { fromHex } from "@aws-sdk/util-hex-encoding";
|
||||
var millionChars = new Uint8Array(1000000);
|
||||
for (var i = 0; i < 1000000; i++) {
|
||||
millionChars[i] = 97;
|
||||
}
|
||||
export var hashTestVectors = [
|
||||
[
|
||||
Uint8Array.from([97, 98, 99]),
|
||||
fromHex("ba7816bf8f01cfea414140de5dae2223b00361a396177a9cb410ff61f20015ad")
|
||||
],
|
||||
[
|
||||
new Uint8Array(0),
|
||||
fromHex("e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855")
|
||||
],
|
||||
[
|
||||
fromHex("61"),
|
||||
fromHex("ca978112ca1bbdcafac231b39a23dc4da786eff8147c4e72b9807785afee48bb")
|
||||
],
|
||||
[
|
||||
fromHex("6161"),
|
||||
fromHex("961b6dd3ede3cb8ecbaacbd68de040cd78eb2ed5889130cceb4c49268ea4d506")
|
||||
],
|
||||
[
|
||||
fromHex("616161"),
|
||||
fromHex("9834876dcfb05cb167a5c24953eba58c4ac89b1adf57f28f2f9d09af107ee8f0")
|
||||
],
|
||||
[
|
||||
fromHex("61616161"),
|
||||
fromHex("61be55a8e2f6b4e172338bddf184d6dbee29c98853e0a0485ecee7f27b9af0b4")
|
||||
],
|
||||
[
|
||||
fromHex("6161616161"),
|
||||
fromHex("ed968e840d10d2d313a870bc131a4e2c311d7ad09bdf32b3418147221f51a6e2")
|
||||
],
|
||||
[
|
||||
fromHex("616161616161"),
|
||||
fromHex("ed02457b5c41d964dbd2f2a609d63fe1bb7528dbe55e1abf5b52c249cd735797")
|
||||
],
|
||||
[
|
||||
fromHex("61616161616161"),
|
||||
fromHex("e46240714b5db3a23eee60479a623efba4d633d27fe4f03c904b9e219a7fbe60")
|
||||
],
|
||||
[
|
||||
fromHex("6161616161616161"),
|
||||
fromHex("1f3ce40415a2081fa3eee75fc39fff8e56c22270d1a978a7249b592dcebd20b4")
|
||||
],
|
||||
[
|
||||
fromHex("616161616161616161"),
|
||||
fromHex("f2aca93b80cae681221f0445fa4e2cae8a1f9f8fa1e1741d9639caad222f537d")
|
||||
],
|
||||
[
|
||||
fromHex("61616161616161616161"),
|
||||
fromHex("bf2cb58a68f684d95a3b78ef8f661c9a4e5b09e82cc8f9cc88cce90528caeb27")
|
||||
],
|
||||
[
|
||||
fromHex("6161616161616161616161"),
|
||||
fromHex("28cb017dfc99073aa1b47c1b30f413e3ce774c4991eb4158de50f9dbb36d8043")
|
||||
],
|
||||
[
|
||||
fromHex("616161616161616161616161"),
|
||||
fromHex("f24abc34b13fade76e805799f71187da6cd90b9cac373ae65ed57f143bd664e5")
|
||||
],
|
||||
[
|
||||
fromHex("61616161616161616161616161"),
|
||||
fromHex("a689d786e81340e45511dec6c7ab2d978434e5db123362450fe10cfac70d19d0")
|
||||
],
|
||||
[
|
||||
fromHex("6161616161616161616161616161"),
|
||||
fromHex("82cab7df0abfb9d95dca4e5937ce2968c798c726fea48c016bf9763221efda13")
|
||||
],
|
||||
[
|
||||
fromHex("616161616161616161616161616161"),
|
||||
fromHex("ef2df0b539c6c23de0f4cbe42648c301ae0e22e887340a4599fb4ef4e2678e48")
|
||||
],
|
||||
[
|
||||
fromHex("61616161616161616161616161616161"),
|
||||
fromHex("0c0beacef8877bbf2416eb00f2b5dc96354e26dd1df5517320459b1236860f8c")
|
||||
],
|
||||
[
|
||||
fromHex("6161616161616161616161616161616161"),
|
||||
fromHex("b860666ee2966dd8f903be44ee605c6e1366f926d9f17a8f49937d11624eb99d")
|
||||
],
|
||||
[
|
||||
fromHex("616161616161616161616161616161616161"),
|
||||
fromHex("c926defaaa3d13eda2fc63a553bb7fb7326bece6e7cb67ca5296e4727d89bab4")
|
||||
],
|
||||
[
|
||||
fromHex("61616161616161616161616161616161616161"),
|
||||
fromHex("a0b4aaab8a966e2193ba172d68162c4656860197f256b5f45f0203397ff3f99c")
|
||||
],
|
||||
[
|
||||
fromHex("6161616161616161616161616161616161616161"),
|
||||
fromHex("42492da06234ad0ac76f5d5debdb6d1ae027cffbe746a1c13b89bb8bc0139137")
|
||||
],
|
||||
[
|
||||
fromHex("616161616161616161616161616161616161616161"),
|
||||
fromHex("7df8e299c834de198e264c3e374bc58ecd9382252a705c183beb02f275571e3b")
|
||||
],
|
||||
[
|
||||
fromHex("61616161616161616161616161616161616161616161"),
|
||||
fromHex("ec7c494df6d2a7ea36668d656e6b8979e33641bfea378c15038af3964db057a3")
|
||||
],
|
||||
[
|
||||
fromHex("6161616161616161616161616161616161616161616161"),
|
||||
fromHex("897d3e95b65f26676081f8b9f3a98b6ee4424566303e8d4e7c7522ebae219eab")
|
||||
],
|
||||
[
|
||||
fromHex("616161616161616161616161616161616161616161616161"),
|
||||
fromHex("09f61f8d9cd65e6a0c258087c485b6293541364e42bd97b2d7936580c8aa3c54")
|
||||
],
|
||||
[
|
||||
fromHex("61616161616161616161616161616161616161616161616161"),
|
||||
fromHex("2f521e2a7d0bd812cbc035f4ed6806eb8d851793b04ba147e8f66b72f5d1f20f")
|
||||
],
|
||||
[
|
||||
fromHex("6161616161616161616161616161616161616161616161616161"),
|
||||
fromHex("9976d549a25115dab4e36d0c1fb8f31cb07da87dd83275977360eb7dc09e88de")
|
||||
],
|
||||
[
|
||||
fromHex("616161616161616161616161616161616161616161616161616161"),
|
||||
fromHex("cc0616e61cbd6e8e5e34e9fb2d320f37de915820206f5696c31f1fbd24aa16de")
|
||||
],
|
||||
[
|
||||
fromHex("61616161616161616161616161616161616161616161616161616161"),
|
||||
fromHex("9c547cb8115a44883b9f70ba68f75117cd55359c92611875e386f8af98c172ab")
|
||||
],
|
||||
[
|
||||
fromHex("6161616161616161616161616161616161616161616161616161616161"),
|
||||
fromHex("6913c9c7fd42fe23df8b6bcd4dbaf1c17748948d97f2980b432319c39eddcf6c")
|
||||
],
|
||||
[
|
||||
fromHex("616161616161616161616161616161616161616161616161616161616161"),
|
||||
fromHex("3a54fc0cbc0b0ef48b6507b7788096235d10292dd3ae24e22f5aa062d4f9864a")
|
||||
],
|
||||
[
|
||||
fromHex("61616161616161616161616161616161616161616161616161616161616161"),
|
||||
fromHex("61c60b487d1a921e0bcc9bf853dda0fb159b30bf57b2e2d2c753b00be15b5a09")
|
||||
],
|
||||
[
|
||||
fromHex("6161616161616161616161616161616161616161616161616161616161616161"),
|
||||
fromHex("3ba3f5f43b92602683c19aee62a20342b084dd5971ddd33808d81a328879a547")
|
||||
],
|
||||
[
|
||||
fromHex("616161616161616161616161616161616161616161616161616161616161616161"),
|
||||
fromHex("852785c805c77e71a22340a54e9d95933ed49121e7d2bf3c2d358854bc1359ea")
|
||||
],
|
||||
[
|
||||
fromHex("61616161616161616161616161616161616161616161616161616161616161616161"),
|
||||
fromHex("a27c896c4859204843166af66f0e902b9c3b3ed6d2fd13d435abc020065c526f")
|
||||
],
|
||||
[
|
||||
fromHex("6161616161616161616161616161616161616161616161616161616161616161616161"),
|
||||
fromHex("629362afc62c74497caed2272e30f8125ecd0965f8d8d7cfc4e260f7f8dd319d")
|
||||
],
|
||||
[
|
||||
fromHex("616161616161616161616161616161616161616161616161616161616161616161616161"),
|
||||
fromHex("22c1d24bcd03e9aee9832efccd6da613fc702793178e5f12c945c7b67ddda933")
|
||||
],
|
||||
[
|
||||
fromHex("61616161616161616161616161616161616161616161616161616161616161616161616161"),
|
||||
fromHex("21ec055b38ce759cd4d0f477e9bdec2c5b8199945db4439bae334a964df6246c")
|
||||
],
|
||||
[
|
||||
fromHex("6161616161616161616161616161616161616161616161616161616161616161616161616161"),
|
||||
fromHex("365a9c3e2c2af0a56e47a9dac51c2c5381bf8f41273bad3175e0e619126ad087")
|
||||
],
|
||||
[
|
||||
fromHex("616161616161616161616161616161616161616161616161616161616161616161616161616161"),
|
||||
fromHex("b4d5e56e929ba4cda349e9274e3603d0be246b82016bca20f363963c5f2d6845")
|
||||
],
|
||||
[
|
||||
fromHex("61616161616161616161616161616161616161616161616161616161616161616161616161616161"),
|
||||
fromHex("e33cdf9c7f7120b98e8c78408953e07f2ecd183006b5606df349b4c212acf43e")
|
||||
],
|
||||
[
|
||||
fromHex("6161616161616161616161616161616161616161616161616161616161616161616161616161616161"),
|
||||
fromHex("c0f8bd4dbc2b0c03107c1c37913f2a7501f521467f45dd0fef6958e9a4692719")
|
||||
],
|
||||
[
|
||||
fromHex("616161616161616161616161616161616161616161616161616161616161616161616161616161616161"),
|
||||
fromHex("7a538607fdaab9296995929f451565bbb8142e1844117322aafd2b3d76b01aff")
|
||||
],
|
||||
[
|
||||
fromHex("61616161616161616161616161616161616161616161616161616161616161616161616161616161616161"),
|
||||
fromHex("66d34fba71f8f450f7e45598853e53bfc23bbd129027cbb131a2f4ffd7878cd0")
|
||||
],
|
||||
[
|
||||
fromHex("6161616161616161616161616161616161616161616161616161616161616161616161616161616161616161"),
|
||||
fromHex("16849877c6c21ef0bfa68e4f6747300ddb171b170b9f00e189edc4c2fc4db93e")
|
||||
],
|
||||
[
|
||||
fromHex("616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161"),
|
||||
fromHex("52789e3423b72beeb898456a4f49662e46b0cbb960784c5ef4b1399d327e7c27")
|
||||
],
|
||||
[
|
||||
fromHex("61616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161"),
|
||||
fromHex("6643110c5628fff59edf76d82d5bf573bf800f16a4d65dfb1e5d6f1a46296d0b")
|
||||
],
|
||||
[
|
||||
fromHex("6161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161"),
|
||||
fromHex("11eaed932c6c6fddfc2efc394e609facf4abe814fc6180d03b14fce13a07d0e5")
|
||||
],
|
||||
[
|
||||
fromHex("616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161"),
|
||||
fromHex("97daac0ee9998dfcad6c9c0970da5ca411c86233a944c25b47566f6a7bc1ddd5")
|
||||
],
|
||||
[
|
||||
fromHex("61616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161"),
|
||||
fromHex("8f9bec6a62dd28ebd36d1227745592de6658b36974a3bb98a4c582f683ea6c42")
|
||||
],
|
||||
[
|
||||
fromHex("6161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161"),
|
||||
fromHex("160b4e433e384e05e537dc59b467f7cb2403f0214db15c5db58862a3f1156d2e")
|
||||
],
|
||||
[
|
||||
fromHex("616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161"),
|
||||
fromHex("bfc5fe0e360152ca98c50fab4ed7e3078c17debc2917740d5000913b686ca129")
|
||||
],
|
||||
[
|
||||
fromHex("61616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161"),
|
||||
fromHex("6c1b3dc7a706b9dc81352a6716b9c666c608d8626272c64b914ab05572fc6e84")
|
||||
],
|
||||
[
|
||||
fromHex("6161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161"),
|
||||
fromHex("abe346a7259fc90b4c27185419628e5e6af6466b1ae9b5446cac4bfc26cf05c4")
|
||||
],
|
||||
[
|
||||
fromHex("616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161"),
|
||||
fromHex("a3f01b6939256127582ac8ae9fb47a382a244680806a3f613a118851c1ca1d47")
|
||||
],
|
||||
[
|
||||
fromHex("61616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161"),
|
||||
fromHex("9f4390f8d30c2dd92ec9f095b65e2b9ae9b0a925a5258e241c9f1e910f734318")
|
||||
],
|
||||
[
|
||||
fromHex("6161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161"),
|
||||
fromHex("b35439a4ac6f0948b6d6f9e3c6af0f5f590ce20f1bde7090ef7970686ec6738a")
|
||||
],
|
||||
[
|
||||
fromHex("616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161"),
|
||||
fromHex("f13b2d724659eb3bf47f2dd6af1accc87b81f09f59f2b75e5c0bed6589dfe8c6")
|
||||
],
|
||||
[
|
||||
fromHex("61616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161"),
|
||||
fromHex("d5c039b748aa64665782974ec3dc3025c042edf54dcdc2b5de31385b094cb678")
|
||||
],
|
||||
[
|
||||
fromHex("6161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161"),
|
||||
fromHex("111bb261277afd65f0744b247cd3e47d386d71563d0ed995517807d5ebd4fba3")
|
||||
],
|
||||
[
|
||||
fromHex("616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161"),
|
||||
fromHex("11ee391211c6256460b6ed375957fadd8061cafbb31daf967db875aebd5aaad4")
|
||||
],
|
||||
[
|
||||
fromHex("61616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161"),
|
||||
fromHex("35d5fc17cfbbadd00f5e710ada39f194c5ad7c766ad67072245f1fad45f0f530")
|
||||
],
|
||||
[
|
||||
fromHex("6161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161"),
|
||||
fromHex("f506898cc7c2e092f9eb9fadae7ba50383f5b46a2a4fe5597dbb553a78981268")
|
||||
],
|
||||
[
|
||||
fromHex("616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161"),
|
||||
fromHex("7d3e74a05d7db15bce4ad9ec0658ea98e3f06eeecf16b4c6fff2da457ddc2f34")
|
||||
],
|
||||
[
|
||||
fromHex("61616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161"),
|
||||
fromHex("ffe054fe7ae0cb6dc65c3af9b61d5209f439851db43d0ba5997337df154668eb")
|
||||
],
|
||||
[
|
||||
fromHex("de188941a3375d3a8a061e67576e926dc71a7fa3f0cceb97452b4d3227965f9ea8cc75076d9fb9c5417aa5cb30fc22198b34982dbb629e"),
|
||||
fromHex("038051e9c324393bd1ca1978dd0952c2aa3742ca4f1bd5cd4611cea83892d382")
|
||||
],
|
||||
[
|
||||
millionChars,
|
||||
fromHex("cdc76e5c9914fb9281a1c7e284d73e67f1809a48a497200e046d39ccc7112cd0")
|
||||
],
|
||||
[
|
||||
fromHex("aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa"),
|
||||
fromHex("45ad4b37c6e2fc0a2cfcc1b5da524132ec707615c2cae1dbbc43c97aa521db81")
|
||||
]
|
||||
];
|
||||
/**
|
||||
* @see https://tools.ietf.org/html/rfc4231
|
||||
*/
|
||||
export var hmacTestVectors = [
|
||||
[
|
||||
fromHex("0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b"),
|
||||
fromHex("4869205468657265"),
|
||||
fromHex("b0344c61d8db38535ca8afceaf0bf12b881dc200c9833da726e9376c2e32cff7")
|
||||
],
|
||||
[
|
||||
fromHex("4a656665"),
|
||||
fromHex("7768617420646f2079612077616e7420666f72206e6f7468696e673f"),
|
||||
fromHex("5bdcc146bf60754e6a042426089575c75a003f089d2739839dec58b964ec3843")
|
||||
],
|
||||
[
|
||||
fromHex("aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa"),
|
||||
fromHex("dddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddd"),
|
||||
fromHex("773ea91e36800e46854db8ebd09181a72959098b3ef8c122d9635514ced565fe")
|
||||
],
|
||||
[
|
||||
fromHex("0102030405060708090a0b0c0d0e0f10111213141516171819"),
|
||||
fromHex("cdcdcdcdcdcdcdcdcdcdcdcdcdcdcdcdcdcdcdcdcdcdcdcdcdcdcdcdcdcdcdcdcdcdcdcdcdcdcdcdcdcdcdcdcdcdcdcdcdcd"),
|
||||
fromHex("82558a389a443c0ea4cc819899f2083a85f0faa3e578f8077a2e3ff46729665b")
|
||||
],
|
||||
[
|
||||
fromHex("aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa"),
|
||||
fromHex("54657374205573696e67204c6172676572205468616e20426c6f636b2d53697a65204b6579202d2048617368204b6579204669727374"),
|
||||
fromHex("60e431591ee0b67f0d8a26aacbf5b77f8e0bc6213728c5140546040f0ee37f54")
|
||||
],
|
||||
[
|
||||
fromHex("aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa"),
|
||||
fromHex("5468697320697320612074657374207573696e672061206c6172676572207468616e20626c6f636b2d73697a65206b657920616e642061206c6172676572207468616e20626c6f636b2d73697a6520646174612e20546865206b6579206e6565647320746f20626520686173686564206265666f7265206265696e6720757365642062792074686520484d414320616c676f726974686d2e"),
|
||||
fromHex("9b09ffa71b942fcb27635fbcd5b0e944bfdc63644f0713938a7f51535c3a35e2")
|
||||
]
|
||||
];
|
||||
//# sourceMappingURL=knownHashes.fixture.js.map
|
||||
1
backend/node_modules/@aws-crypto/sha256-js/build/module/knownHashes.fixture.js.map
generated
vendored
Normal file
1
backend/node_modules/@aws-crypto/sha256-js/build/module/knownHashes.fixture.js.map
generated
vendored
Normal file
File diff suppressed because one or more lines are too long
32
backend/node_modules/@aws-crypto/sha256-js/package.json
generated
vendored
Normal file
32
backend/node_modules/@aws-crypto/sha256-js/package.json
generated
vendored
Normal file
@@ -0,0 +1,32 @@
|
||||
{
|
||||
"name": "@aws-crypto/sha256-js",
|
||||
"version": "5.2.0",
|
||||
"scripts": {
|
||||
"prepublishOnly": "tsc -p tsconfig.json && tsc -p tsconfig.module.json",
|
||||
"pretest": "tsc -p tsconfig.test.json",
|
||||
"test": "mocha --require ts-node/register test/**/*test.ts"
|
||||
},
|
||||
"main": "./build/main/index.js",
|
||||
"module": "./build/module/index.js",
|
||||
"types": "./build/main/index.d.ts",
|
||||
"repository": {
|
||||
"type": "git",
|
||||
"url": "git@github.com:aws/aws-sdk-js-crypto-helpers.git"
|
||||
},
|
||||
"author": {
|
||||
"name": "AWS Crypto Tools Team",
|
||||
"email": "aws-cryptools@amazon.com",
|
||||
"url": "https://docs.aws.amazon.com/aws-crypto-tools/index.html?id=docs_gateway#lang/en_us"
|
||||
},
|
||||
"homepage": "https://github.com/aws/aws-sdk-js-crypto-helpers/tree/master/packages/sha256-js",
|
||||
"license": "Apache-2.0",
|
||||
"dependencies": {
|
||||
"@aws-crypto/util": "^5.2.0",
|
||||
"@aws-sdk/types": "^3.222.0",
|
||||
"tslib": "^2.6.2"
|
||||
},
|
||||
"engines": {
|
||||
"node": ">=16.0.0"
|
||||
},
|
||||
"gitHead": "c11b171b35ec5c093364f0e0d8dc4ab1af68e748"
|
||||
}
|
||||
164
backend/node_modules/@aws-crypto/sha256-js/src/RawSha256.ts
generated
vendored
Normal file
164
backend/node_modules/@aws-crypto/sha256-js/src/RawSha256.ts
generated
vendored
Normal file
@@ -0,0 +1,164 @@
|
||||
import {
|
||||
BLOCK_SIZE,
|
||||
DIGEST_LENGTH,
|
||||
INIT,
|
||||
KEY,
|
||||
MAX_HASHABLE_LENGTH
|
||||
} from "./constants";
|
||||
|
||||
/**
|
||||
* @internal
|
||||
*/
|
||||
export class RawSha256 {
|
||||
private state: Int32Array = Int32Array.from(INIT);
|
||||
private temp: Int32Array = new Int32Array(64);
|
||||
private buffer: Uint8Array = new Uint8Array(64);
|
||||
private bufferLength: number = 0;
|
||||
private bytesHashed: number = 0;
|
||||
|
||||
/**
|
||||
* @internal
|
||||
*/
|
||||
finished: boolean = false;
|
||||
|
||||
update(data: Uint8Array): void {
|
||||
if (this.finished) {
|
||||
throw new Error("Attempted to update an already finished hash.");
|
||||
}
|
||||
|
||||
let position = 0;
|
||||
let { byteLength } = data;
|
||||
this.bytesHashed += byteLength;
|
||||
|
||||
if (this.bytesHashed * 8 > MAX_HASHABLE_LENGTH) {
|
||||
throw new Error("Cannot hash more than 2^53 - 1 bits");
|
||||
}
|
||||
|
||||
while (byteLength > 0) {
|
||||
this.buffer[this.bufferLength++] = data[position++];
|
||||
byteLength--;
|
||||
|
||||
if (this.bufferLength === BLOCK_SIZE) {
|
||||
this.hashBuffer();
|
||||
this.bufferLength = 0;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
digest(): Uint8Array {
|
||||
if (!this.finished) {
|
||||
const bitsHashed = this.bytesHashed * 8;
|
||||
const bufferView = new DataView(
|
||||
this.buffer.buffer,
|
||||
this.buffer.byteOffset,
|
||||
this.buffer.byteLength
|
||||
);
|
||||
|
||||
const undecoratedLength = this.bufferLength;
|
||||
bufferView.setUint8(this.bufferLength++, 0x80);
|
||||
|
||||
// Ensure the final block has enough room for the hashed length
|
||||
if (undecoratedLength % BLOCK_SIZE >= BLOCK_SIZE - 8) {
|
||||
for (let i = this.bufferLength; i < BLOCK_SIZE; i++) {
|
||||
bufferView.setUint8(i, 0);
|
||||
}
|
||||
this.hashBuffer();
|
||||
this.bufferLength = 0;
|
||||
}
|
||||
|
||||
for (let i = this.bufferLength; i < BLOCK_SIZE - 8; i++) {
|
||||
bufferView.setUint8(i, 0);
|
||||
}
|
||||
bufferView.setUint32(
|
||||
BLOCK_SIZE - 8,
|
||||
Math.floor(bitsHashed / 0x100000000),
|
||||
true
|
||||
);
|
||||
bufferView.setUint32(BLOCK_SIZE - 4, bitsHashed);
|
||||
|
||||
this.hashBuffer();
|
||||
|
||||
this.finished = true;
|
||||
}
|
||||
|
||||
// The value in state is little-endian rather than big-endian, so flip
|
||||
// each word into a new Uint8Array
|
||||
const out = new Uint8Array(DIGEST_LENGTH);
|
||||
for (let i = 0; i < 8; i++) {
|
||||
out[i * 4] = (this.state[i] >>> 24) & 0xff;
|
||||
out[i * 4 + 1] = (this.state[i] >>> 16) & 0xff;
|
||||
out[i * 4 + 2] = (this.state[i] >>> 8) & 0xff;
|
||||
out[i * 4 + 3] = (this.state[i] >>> 0) & 0xff;
|
||||
}
|
||||
|
||||
return out;
|
||||
}
|
||||
|
||||
private hashBuffer(): void {
|
||||
const { buffer, state } = this;
|
||||
|
||||
let state0 = state[0],
|
||||
state1 = state[1],
|
||||
state2 = state[2],
|
||||
state3 = state[3],
|
||||
state4 = state[4],
|
||||
state5 = state[5],
|
||||
state6 = state[6],
|
||||
state7 = state[7];
|
||||
|
||||
for (let i = 0; i < BLOCK_SIZE; i++) {
|
||||
if (i < 16) {
|
||||
this.temp[i] =
|
||||
((buffer[i * 4] & 0xff) << 24) |
|
||||
((buffer[i * 4 + 1] & 0xff) << 16) |
|
||||
((buffer[i * 4 + 2] & 0xff) << 8) |
|
||||
(buffer[i * 4 + 3] & 0xff);
|
||||
} else {
|
||||
let u = this.temp[i - 2];
|
||||
const t1 =
|
||||
((u >>> 17) | (u << 15)) ^ ((u >>> 19) | (u << 13)) ^ (u >>> 10);
|
||||
|
||||
u = this.temp[i - 15];
|
||||
const t2 =
|
||||
((u >>> 7) | (u << 25)) ^ ((u >>> 18) | (u << 14)) ^ (u >>> 3);
|
||||
|
||||
this.temp[i] =
|
||||
((t1 + this.temp[i - 7]) | 0) + ((t2 + this.temp[i - 16]) | 0);
|
||||
}
|
||||
|
||||
const t1 =
|
||||
((((((state4 >>> 6) | (state4 << 26)) ^
|
||||
((state4 >>> 11) | (state4 << 21)) ^
|
||||
((state4 >>> 25) | (state4 << 7))) +
|
||||
((state4 & state5) ^ (~state4 & state6))) |
|
||||
0) +
|
||||
((state7 + ((KEY[i] + this.temp[i]) | 0)) | 0)) |
|
||||
0;
|
||||
|
||||
const t2 =
|
||||
((((state0 >>> 2) | (state0 << 30)) ^
|
||||
((state0 >>> 13) | (state0 << 19)) ^
|
||||
((state0 >>> 22) | (state0 << 10))) +
|
||||
((state0 & state1) ^ (state0 & state2) ^ (state1 & state2))) |
|
||||
0;
|
||||
|
||||
state7 = state6;
|
||||
state6 = state5;
|
||||
state5 = state4;
|
||||
state4 = (state3 + t1) | 0;
|
||||
state3 = state2;
|
||||
state2 = state1;
|
||||
state1 = state0;
|
||||
state0 = (t1 + t2) | 0;
|
||||
}
|
||||
|
||||
state[0] += state0;
|
||||
state[1] += state1;
|
||||
state[2] += state2;
|
||||
state[3] += state3;
|
||||
state[4] += state4;
|
||||
state[5] += state5;
|
||||
state[6] += state6;
|
||||
state[7] += state7;
|
||||
}
|
||||
}
|
||||
98
backend/node_modules/@aws-crypto/sha256-js/src/constants.ts
generated
vendored
Normal file
98
backend/node_modules/@aws-crypto/sha256-js/src/constants.ts
generated
vendored
Normal file
@@ -0,0 +1,98 @@
|
||||
/**
|
||||
* @internal
|
||||
*/
|
||||
export const BLOCK_SIZE: number = 64;
|
||||
|
||||
/**
|
||||
* @internal
|
||||
*/
|
||||
export const DIGEST_LENGTH: number = 32;
|
||||
|
||||
/**
|
||||
* @internal
|
||||
*/
|
||||
export const KEY = new Uint32Array([
|
||||
0x428a2f98,
|
||||
0x71374491,
|
||||
0xb5c0fbcf,
|
||||
0xe9b5dba5,
|
||||
0x3956c25b,
|
||||
0x59f111f1,
|
||||
0x923f82a4,
|
||||
0xab1c5ed5,
|
||||
0xd807aa98,
|
||||
0x12835b01,
|
||||
0x243185be,
|
||||
0x550c7dc3,
|
||||
0x72be5d74,
|
||||
0x80deb1fe,
|
||||
0x9bdc06a7,
|
||||
0xc19bf174,
|
||||
0xe49b69c1,
|
||||
0xefbe4786,
|
||||
0x0fc19dc6,
|
||||
0x240ca1cc,
|
||||
0x2de92c6f,
|
||||
0x4a7484aa,
|
||||
0x5cb0a9dc,
|
||||
0x76f988da,
|
||||
0x983e5152,
|
||||
0xa831c66d,
|
||||
0xb00327c8,
|
||||
0xbf597fc7,
|
||||
0xc6e00bf3,
|
||||
0xd5a79147,
|
||||
0x06ca6351,
|
||||
0x14292967,
|
||||
0x27b70a85,
|
||||
0x2e1b2138,
|
||||
0x4d2c6dfc,
|
||||
0x53380d13,
|
||||
0x650a7354,
|
||||
0x766a0abb,
|
||||
0x81c2c92e,
|
||||
0x92722c85,
|
||||
0xa2bfe8a1,
|
||||
0xa81a664b,
|
||||
0xc24b8b70,
|
||||
0xc76c51a3,
|
||||
0xd192e819,
|
||||
0xd6990624,
|
||||
0xf40e3585,
|
||||
0x106aa070,
|
||||
0x19a4c116,
|
||||
0x1e376c08,
|
||||
0x2748774c,
|
||||
0x34b0bcb5,
|
||||
0x391c0cb3,
|
||||
0x4ed8aa4a,
|
||||
0x5b9cca4f,
|
||||
0x682e6ff3,
|
||||
0x748f82ee,
|
||||
0x78a5636f,
|
||||
0x84c87814,
|
||||
0x8cc70208,
|
||||
0x90befffa,
|
||||
0xa4506ceb,
|
||||
0xbef9a3f7,
|
||||
0xc67178f2
|
||||
]);
|
||||
|
||||
/**
|
||||
* @internal
|
||||
*/
|
||||
export const INIT = [
|
||||
0x6a09e667,
|
||||
0xbb67ae85,
|
||||
0x3c6ef372,
|
||||
0xa54ff53a,
|
||||
0x510e527f,
|
||||
0x9b05688c,
|
||||
0x1f83d9ab,
|
||||
0x5be0cd19
|
||||
];
|
||||
|
||||
/**
|
||||
* @internal
|
||||
*/
|
||||
export const MAX_HASHABLE_LENGTH = 2 ** 53 - 1;
|
||||
1
backend/node_modules/@aws-crypto/sha256-js/src/index.ts
generated
vendored
Normal file
1
backend/node_modules/@aws-crypto/sha256-js/src/index.ts
generated
vendored
Normal file
@@ -0,0 +1 @@
|
||||
export * from "./jsSha256";
|
||||
94
backend/node_modules/@aws-crypto/sha256-js/src/jsSha256.ts
generated
vendored
Normal file
94
backend/node_modules/@aws-crypto/sha256-js/src/jsSha256.ts
generated
vendored
Normal file
@@ -0,0 +1,94 @@
|
||||
import { BLOCK_SIZE } from "./constants";
|
||||
import { RawSha256 } from "./RawSha256";
|
||||
import { Checksum, SourceData } from "@aws-sdk/types";
|
||||
import { isEmptyData, convertToBuffer } from "@aws-crypto/util";
|
||||
|
||||
export class Sha256 implements Checksum {
|
||||
private readonly secret?: SourceData;
|
||||
private hash: RawSha256;
|
||||
private outer?: RawSha256;
|
||||
private error: any;
|
||||
|
||||
constructor(secret?: SourceData) {
|
||||
this.secret = secret;
|
||||
this.hash = new RawSha256();
|
||||
this.reset();
|
||||
}
|
||||
|
||||
update(toHash: SourceData): void {
|
||||
if (isEmptyData(toHash) || this.error) {
|
||||
return;
|
||||
}
|
||||
|
||||
try {
|
||||
this.hash.update(convertToBuffer(toHash));
|
||||
} catch (e) {
|
||||
this.error = e;
|
||||
}
|
||||
}
|
||||
|
||||
/* This synchronous method keeps compatibility
|
||||
* with the v2 aws-sdk.
|
||||
*/
|
||||
digestSync(): Uint8Array {
|
||||
if (this.error) {
|
||||
throw this.error;
|
||||
}
|
||||
|
||||
if (this.outer) {
|
||||
if (!this.outer.finished) {
|
||||
this.outer.update(this.hash.digest());
|
||||
}
|
||||
|
||||
return this.outer.digest();
|
||||
}
|
||||
|
||||
return this.hash.digest();
|
||||
}
|
||||
|
||||
/* The underlying digest method here is synchronous.
|
||||
* To keep the same interface with the other hash functions
|
||||
* the default is to expose this as an async method.
|
||||
* However, it can sometimes be useful to have a sync method.
|
||||
*/
|
||||
async digest(): Promise<Uint8Array> {
|
||||
return this.digestSync();
|
||||
}
|
||||
|
||||
reset(): void {
|
||||
this.hash = new RawSha256();
|
||||
if (this.secret) {
|
||||
this.outer = new RawSha256();
|
||||
const inner = bufferFromSecret(this.secret);
|
||||
const outer = new Uint8Array(BLOCK_SIZE);
|
||||
outer.set(inner);
|
||||
|
||||
for (let i = 0; i < BLOCK_SIZE; i++) {
|
||||
inner[i] ^= 0x36;
|
||||
outer[i] ^= 0x5c;
|
||||
}
|
||||
|
||||
this.hash.update(inner);
|
||||
this.outer.update(outer);
|
||||
|
||||
// overwrite the copied key in memory
|
||||
for (let i = 0; i < inner.byteLength; i++) {
|
||||
inner[i] = 0;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
function bufferFromSecret(secret: SourceData): Uint8Array {
|
||||
let input = convertToBuffer(secret);
|
||||
|
||||
if (input.byteLength > BLOCK_SIZE) {
|
||||
const bufferHash = new RawSha256();
|
||||
bufferHash.update(input);
|
||||
input = bufferHash.digest();
|
||||
}
|
||||
|
||||
const buffer = new Uint8Array(BLOCK_SIZE);
|
||||
buffer.set(input);
|
||||
return buffer;
|
||||
}
|
||||
401
backend/node_modules/@aws-crypto/sha256-js/src/knownHashes.fixture.ts
generated
vendored
Normal file
401
backend/node_modules/@aws-crypto/sha256-js/src/knownHashes.fixture.ts
generated
vendored
Normal file
@@ -0,0 +1,401 @@
|
||||
import { fromHex } from "@aws-sdk/util-hex-encoding";
|
||||
|
||||
const millionChars = new Uint8Array(1000000);
|
||||
for (let i = 0; i < 1000000; i++) {
|
||||
millionChars[i] = 97;
|
||||
}
|
||||
|
||||
export const hashTestVectors: Array<[Uint8Array, Uint8Array]> = [
|
||||
[
|
||||
Uint8Array.from([97, 98, 99]),
|
||||
fromHex("ba7816bf8f01cfea414140de5dae2223b00361a396177a9cb410ff61f20015ad")
|
||||
],
|
||||
[
|
||||
new Uint8Array(0),
|
||||
fromHex("e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855")
|
||||
],
|
||||
[
|
||||
fromHex("61"),
|
||||
fromHex("ca978112ca1bbdcafac231b39a23dc4da786eff8147c4e72b9807785afee48bb")
|
||||
],
|
||||
[
|
||||
fromHex("6161"),
|
||||
fromHex("961b6dd3ede3cb8ecbaacbd68de040cd78eb2ed5889130cceb4c49268ea4d506")
|
||||
],
|
||||
[
|
||||
fromHex("616161"),
|
||||
fromHex("9834876dcfb05cb167a5c24953eba58c4ac89b1adf57f28f2f9d09af107ee8f0")
|
||||
],
|
||||
[
|
||||
fromHex("61616161"),
|
||||
fromHex("61be55a8e2f6b4e172338bddf184d6dbee29c98853e0a0485ecee7f27b9af0b4")
|
||||
],
|
||||
[
|
||||
fromHex("6161616161"),
|
||||
fromHex("ed968e840d10d2d313a870bc131a4e2c311d7ad09bdf32b3418147221f51a6e2")
|
||||
],
|
||||
[
|
||||
fromHex("616161616161"),
|
||||
fromHex("ed02457b5c41d964dbd2f2a609d63fe1bb7528dbe55e1abf5b52c249cd735797")
|
||||
],
|
||||
[
|
||||
fromHex("61616161616161"),
|
||||
fromHex("e46240714b5db3a23eee60479a623efba4d633d27fe4f03c904b9e219a7fbe60")
|
||||
],
|
||||
[
|
||||
fromHex("6161616161616161"),
|
||||
fromHex("1f3ce40415a2081fa3eee75fc39fff8e56c22270d1a978a7249b592dcebd20b4")
|
||||
],
|
||||
[
|
||||
fromHex("616161616161616161"),
|
||||
fromHex("f2aca93b80cae681221f0445fa4e2cae8a1f9f8fa1e1741d9639caad222f537d")
|
||||
],
|
||||
[
|
||||
fromHex("61616161616161616161"),
|
||||
fromHex("bf2cb58a68f684d95a3b78ef8f661c9a4e5b09e82cc8f9cc88cce90528caeb27")
|
||||
],
|
||||
[
|
||||
fromHex("6161616161616161616161"),
|
||||
fromHex("28cb017dfc99073aa1b47c1b30f413e3ce774c4991eb4158de50f9dbb36d8043")
|
||||
],
|
||||
[
|
||||
fromHex("616161616161616161616161"),
|
||||
fromHex("f24abc34b13fade76e805799f71187da6cd90b9cac373ae65ed57f143bd664e5")
|
||||
],
|
||||
[
|
||||
fromHex("61616161616161616161616161"),
|
||||
fromHex("a689d786e81340e45511dec6c7ab2d978434e5db123362450fe10cfac70d19d0")
|
||||
],
|
||||
[
|
||||
fromHex("6161616161616161616161616161"),
|
||||
fromHex("82cab7df0abfb9d95dca4e5937ce2968c798c726fea48c016bf9763221efda13")
|
||||
],
|
||||
[
|
||||
fromHex("616161616161616161616161616161"),
|
||||
fromHex("ef2df0b539c6c23de0f4cbe42648c301ae0e22e887340a4599fb4ef4e2678e48")
|
||||
],
|
||||
[
|
||||
fromHex("61616161616161616161616161616161"),
|
||||
fromHex("0c0beacef8877bbf2416eb00f2b5dc96354e26dd1df5517320459b1236860f8c")
|
||||
],
|
||||
[
|
||||
fromHex("6161616161616161616161616161616161"),
|
||||
fromHex("b860666ee2966dd8f903be44ee605c6e1366f926d9f17a8f49937d11624eb99d")
|
||||
],
|
||||
[
|
||||
fromHex("616161616161616161616161616161616161"),
|
||||
fromHex("c926defaaa3d13eda2fc63a553bb7fb7326bece6e7cb67ca5296e4727d89bab4")
|
||||
],
|
||||
[
|
||||
fromHex("61616161616161616161616161616161616161"),
|
||||
fromHex("a0b4aaab8a966e2193ba172d68162c4656860197f256b5f45f0203397ff3f99c")
|
||||
],
|
||||
[
|
||||
fromHex("6161616161616161616161616161616161616161"),
|
||||
fromHex("42492da06234ad0ac76f5d5debdb6d1ae027cffbe746a1c13b89bb8bc0139137")
|
||||
],
|
||||
[
|
||||
fromHex("616161616161616161616161616161616161616161"),
|
||||
fromHex("7df8e299c834de198e264c3e374bc58ecd9382252a705c183beb02f275571e3b")
|
||||
],
|
||||
[
|
||||
fromHex("61616161616161616161616161616161616161616161"),
|
||||
fromHex("ec7c494df6d2a7ea36668d656e6b8979e33641bfea378c15038af3964db057a3")
|
||||
],
|
||||
[
|
||||
fromHex("6161616161616161616161616161616161616161616161"),
|
||||
fromHex("897d3e95b65f26676081f8b9f3a98b6ee4424566303e8d4e7c7522ebae219eab")
|
||||
],
|
||||
[
|
||||
fromHex("616161616161616161616161616161616161616161616161"),
|
||||
fromHex("09f61f8d9cd65e6a0c258087c485b6293541364e42bd97b2d7936580c8aa3c54")
|
||||
],
|
||||
[
|
||||
fromHex("61616161616161616161616161616161616161616161616161"),
|
||||
fromHex("2f521e2a7d0bd812cbc035f4ed6806eb8d851793b04ba147e8f66b72f5d1f20f")
|
||||
],
|
||||
[
|
||||
fromHex("6161616161616161616161616161616161616161616161616161"),
|
||||
fromHex("9976d549a25115dab4e36d0c1fb8f31cb07da87dd83275977360eb7dc09e88de")
|
||||
],
|
||||
[
|
||||
fromHex("616161616161616161616161616161616161616161616161616161"),
|
||||
fromHex("cc0616e61cbd6e8e5e34e9fb2d320f37de915820206f5696c31f1fbd24aa16de")
|
||||
],
|
||||
[
|
||||
fromHex("61616161616161616161616161616161616161616161616161616161"),
|
||||
fromHex("9c547cb8115a44883b9f70ba68f75117cd55359c92611875e386f8af98c172ab")
|
||||
],
|
||||
[
|
||||
fromHex("6161616161616161616161616161616161616161616161616161616161"),
|
||||
fromHex("6913c9c7fd42fe23df8b6bcd4dbaf1c17748948d97f2980b432319c39eddcf6c")
|
||||
],
|
||||
[
|
||||
fromHex("616161616161616161616161616161616161616161616161616161616161"),
|
||||
fromHex("3a54fc0cbc0b0ef48b6507b7788096235d10292dd3ae24e22f5aa062d4f9864a")
|
||||
],
|
||||
[
|
||||
fromHex("61616161616161616161616161616161616161616161616161616161616161"),
|
||||
fromHex("61c60b487d1a921e0bcc9bf853dda0fb159b30bf57b2e2d2c753b00be15b5a09")
|
||||
],
|
||||
[
|
||||
fromHex("6161616161616161616161616161616161616161616161616161616161616161"),
|
||||
fromHex("3ba3f5f43b92602683c19aee62a20342b084dd5971ddd33808d81a328879a547")
|
||||
],
|
||||
[
|
||||
fromHex(
|
||||
"616161616161616161616161616161616161616161616161616161616161616161"
|
||||
),
|
||||
fromHex("852785c805c77e71a22340a54e9d95933ed49121e7d2bf3c2d358854bc1359ea")
|
||||
],
|
||||
[
|
||||
fromHex(
|
||||
"61616161616161616161616161616161616161616161616161616161616161616161"
|
||||
),
|
||||
fromHex("a27c896c4859204843166af66f0e902b9c3b3ed6d2fd13d435abc020065c526f")
|
||||
],
|
||||
[
|
||||
fromHex(
|
||||
"6161616161616161616161616161616161616161616161616161616161616161616161"
|
||||
),
|
||||
fromHex("629362afc62c74497caed2272e30f8125ecd0965f8d8d7cfc4e260f7f8dd319d")
|
||||
],
|
||||
[
|
||||
fromHex(
|
||||
"616161616161616161616161616161616161616161616161616161616161616161616161"
|
||||
),
|
||||
fromHex("22c1d24bcd03e9aee9832efccd6da613fc702793178e5f12c945c7b67ddda933")
|
||||
],
|
||||
[
|
||||
fromHex(
|
||||
"61616161616161616161616161616161616161616161616161616161616161616161616161"
|
||||
),
|
||||
fromHex("21ec055b38ce759cd4d0f477e9bdec2c5b8199945db4439bae334a964df6246c")
|
||||
],
|
||||
[
|
||||
fromHex(
|
||||
"6161616161616161616161616161616161616161616161616161616161616161616161616161"
|
||||
),
|
||||
fromHex("365a9c3e2c2af0a56e47a9dac51c2c5381bf8f41273bad3175e0e619126ad087")
|
||||
],
|
||||
[
|
||||
fromHex(
|
||||
"616161616161616161616161616161616161616161616161616161616161616161616161616161"
|
||||
),
|
||||
fromHex("b4d5e56e929ba4cda349e9274e3603d0be246b82016bca20f363963c5f2d6845")
|
||||
],
|
||||
[
|
||||
fromHex(
|
||||
"61616161616161616161616161616161616161616161616161616161616161616161616161616161"
|
||||
),
|
||||
fromHex("e33cdf9c7f7120b98e8c78408953e07f2ecd183006b5606df349b4c212acf43e")
|
||||
],
|
||||
[
|
||||
fromHex(
|
||||
"6161616161616161616161616161616161616161616161616161616161616161616161616161616161"
|
||||
),
|
||||
fromHex("c0f8bd4dbc2b0c03107c1c37913f2a7501f521467f45dd0fef6958e9a4692719")
|
||||
],
|
||||
[
|
||||
fromHex(
|
||||
"616161616161616161616161616161616161616161616161616161616161616161616161616161616161"
|
||||
),
|
||||
fromHex("7a538607fdaab9296995929f451565bbb8142e1844117322aafd2b3d76b01aff")
|
||||
],
|
||||
[
|
||||
fromHex(
|
||||
"61616161616161616161616161616161616161616161616161616161616161616161616161616161616161"
|
||||
),
|
||||
fromHex("66d34fba71f8f450f7e45598853e53bfc23bbd129027cbb131a2f4ffd7878cd0")
|
||||
],
|
||||
[
|
||||
fromHex(
|
||||
"6161616161616161616161616161616161616161616161616161616161616161616161616161616161616161"
|
||||
),
|
||||
fromHex("16849877c6c21ef0bfa68e4f6747300ddb171b170b9f00e189edc4c2fc4db93e")
|
||||
],
|
||||
[
|
||||
fromHex(
|
||||
"616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161"
|
||||
),
|
||||
fromHex("52789e3423b72beeb898456a4f49662e46b0cbb960784c5ef4b1399d327e7c27")
|
||||
],
|
||||
[
|
||||
fromHex(
|
||||
"61616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161"
|
||||
),
|
||||
fromHex("6643110c5628fff59edf76d82d5bf573bf800f16a4d65dfb1e5d6f1a46296d0b")
|
||||
],
|
||||
[
|
||||
fromHex(
|
||||
"6161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161"
|
||||
),
|
||||
fromHex("11eaed932c6c6fddfc2efc394e609facf4abe814fc6180d03b14fce13a07d0e5")
|
||||
],
|
||||
[
|
||||
fromHex(
|
||||
"616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161"
|
||||
),
|
||||
fromHex("97daac0ee9998dfcad6c9c0970da5ca411c86233a944c25b47566f6a7bc1ddd5")
|
||||
],
|
||||
[
|
||||
fromHex(
|
||||
"61616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161"
|
||||
),
|
||||
fromHex("8f9bec6a62dd28ebd36d1227745592de6658b36974a3bb98a4c582f683ea6c42")
|
||||
],
|
||||
[
|
||||
fromHex(
|
||||
"6161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161"
|
||||
),
|
||||
fromHex("160b4e433e384e05e537dc59b467f7cb2403f0214db15c5db58862a3f1156d2e")
|
||||
],
|
||||
[
|
||||
fromHex(
|
||||
"616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161"
|
||||
),
|
||||
fromHex("bfc5fe0e360152ca98c50fab4ed7e3078c17debc2917740d5000913b686ca129")
|
||||
],
|
||||
[
|
||||
fromHex(
|
||||
"61616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161"
|
||||
),
|
||||
fromHex("6c1b3dc7a706b9dc81352a6716b9c666c608d8626272c64b914ab05572fc6e84")
|
||||
],
|
||||
[
|
||||
fromHex(
|
||||
"6161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161"
|
||||
),
|
||||
fromHex("abe346a7259fc90b4c27185419628e5e6af6466b1ae9b5446cac4bfc26cf05c4")
|
||||
],
|
||||
[
|
||||
fromHex(
|
||||
"616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161"
|
||||
),
|
||||
fromHex("a3f01b6939256127582ac8ae9fb47a382a244680806a3f613a118851c1ca1d47")
|
||||
],
|
||||
[
|
||||
fromHex(
|
||||
"61616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161"
|
||||
),
|
||||
fromHex("9f4390f8d30c2dd92ec9f095b65e2b9ae9b0a925a5258e241c9f1e910f734318")
|
||||
],
|
||||
[
|
||||
fromHex(
|
||||
"6161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161"
|
||||
),
|
||||
fromHex("b35439a4ac6f0948b6d6f9e3c6af0f5f590ce20f1bde7090ef7970686ec6738a")
|
||||
],
|
||||
[
|
||||
fromHex(
|
||||
"616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161"
|
||||
),
|
||||
fromHex("f13b2d724659eb3bf47f2dd6af1accc87b81f09f59f2b75e5c0bed6589dfe8c6")
|
||||
],
|
||||
[
|
||||
fromHex(
|
||||
"61616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161"
|
||||
),
|
||||
fromHex("d5c039b748aa64665782974ec3dc3025c042edf54dcdc2b5de31385b094cb678")
|
||||
],
|
||||
[
|
||||
fromHex(
|
||||
"6161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161"
|
||||
),
|
||||
fromHex("111bb261277afd65f0744b247cd3e47d386d71563d0ed995517807d5ebd4fba3")
|
||||
],
|
||||
[
|
||||
fromHex(
|
||||
"616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161"
|
||||
),
|
||||
fromHex("11ee391211c6256460b6ed375957fadd8061cafbb31daf967db875aebd5aaad4")
|
||||
],
|
||||
[
|
||||
fromHex(
|
||||
"61616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161"
|
||||
),
|
||||
fromHex("35d5fc17cfbbadd00f5e710ada39f194c5ad7c766ad67072245f1fad45f0f530")
|
||||
],
|
||||
[
|
||||
fromHex(
|
||||
"6161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161"
|
||||
),
|
||||
fromHex("f506898cc7c2e092f9eb9fadae7ba50383f5b46a2a4fe5597dbb553a78981268")
|
||||
],
|
||||
[
|
||||
fromHex(
|
||||
"616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161"
|
||||
),
|
||||
fromHex("7d3e74a05d7db15bce4ad9ec0658ea98e3f06eeecf16b4c6fff2da457ddc2f34")
|
||||
],
|
||||
[
|
||||
fromHex(
|
||||
"61616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161"
|
||||
),
|
||||
fromHex("ffe054fe7ae0cb6dc65c3af9b61d5209f439851db43d0ba5997337df154668eb")
|
||||
],
|
||||
[
|
||||
fromHex(
|
||||
"de188941a3375d3a8a061e67576e926dc71a7fa3f0cceb97452b4d3227965f9ea8cc75076d9fb9c5417aa5cb30fc22198b34982dbb629e"
|
||||
),
|
||||
fromHex("038051e9c324393bd1ca1978dd0952c2aa3742ca4f1bd5cd4611cea83892d382")
|
||||
],
|
||||
[
|
||||
millionChars,
|
||||
fromHex("cdc76e5c9914fb9281a1c7e284d73e67f1809a48a497200e046d39ccc7112cd0")
|
||||
],
|
||||
[
|
||||
fromHex(
|
||||
"aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa"
|
||||
),
|
||||
fromHex("45ad4b37c6e2fc0a2cfcc1b5da524132ec707615c2cae1dbbc43c97aa521db81")
|
||||
]
|
||||
];
|
||||
|
||||
/**
|
||||
* @see https://tools.ietf.org/html/rfc4231
|
||||
*/
|
||||
export const hmacTestVectors: Array<[Uint8Array, Uint8Array, Uint8Array]> = [
|
||||
[
|
||||
fromHex("0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b"),
|
||||
fromHex("4869205468657265"),
|
||||
fromHex("b0344c61d8db38535ca8afceaf0bf12b881dc200c9833da726e9376c2e32cff7")
|
||||
],
|
||||
[
|
||||
fromHex("4a656665"),
|
||||
fromHex("7768617420646f2079612077616e7420666f72206e6f7468696e673f"),
|
||||
fromHex("5bdcc146bf60754e6a042426089575c75a003f089d2739839dec58b964ec3843")
|
||||
],
|
||||
[
|
||||
fromHex("aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa"),
|
||||
fromHex(
|
||||
"dddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddd"
|
||||
),
|
||||
fromHex("773ea91e36800e46854db8ebd09181a72959098b3ef8c122d9635514ced565fe")
|
||||
],
|
||||
[
|
||||
fromHex("0102030405060708090a0b0c0d0e0f10111213141516171819"),
|
||||
fromHex(
|
||||
"cdcdcdcdcdcdcdcdcdcdcdcdcdcdcdcdcdcdcdcdcdcdcdcdcdcdcdcdcdcdcdcdcdcdcdcdcdcdcdcdcdcdcdcdcdcdcdcdcdcd"
|
||||
),
|
||||
fromHex("82558a389a443c0ea4cc819899f2083a85f0faa3e578f8077a2e3ff46729665b")
|
||||
],
|
||||
[
|
||||
fromHex(
|
||||
"aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa"
|
||||
),
|
||||
fromHex(
|
||||
"54657374205573696e67204c6172676572205468616e20426c6f636b2d53697a65204b6579202d2048617368204b6579204669727374"
|
||||
),
|
||||
fromHex("60e431591ee0b67f0d8a26aacbf5b77f8e0bc6213728c5140546040f0ee37f54")
|
||||
],
|
||||
[
|
||||
fromHex(
|
||||
"aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa"
|
||||
),
|
||||
fromHex(
|
||||
"5468697320697320612074657374207573696e672061206c6172676572207468616e20626c6f636b2d73697a65206b657920616e642061206c6172676572207468616e20626c6f636b2d73697a6520646174612e20546865206b6579206e6565647320746f20626520686173686564206265666f7265206265696e6720757365642062792074686520484d414320616c676f726974686d2e"
|
||||
),
|
||||
fromHex("9b09ffa71b942fcb27635fbcd5b0e944bfdc63644f0713938a7f51535c3a35e2")
|
||||
]
|
||||
];
|
||||
10
backend/node_modules/@aws-crypto/sha256-js/tsconfig.json
generated
vendored
Normal file
10
backend/node_modules/@aws-crypto/sha256-js/tsconfig.json
generated
vendored
Normal file
@@ -0,0 +1,10 @@
|
||||
{
|
||||
"extends": "../tsconfig.json",
|
||||
"compilerOptions": {
|
||||
"rootDir": "./src",
|
||||
"outDir": "./build/main",
|
||||
"lib": ["dom"],
|
||||
},
|
||||
"include": ["src/**/*.ts"],
|
||||
"exclude": ["node_modules/**"]
|
||||
}
|
||||
7
backend/node_modules/@aws-crypto/sha256-js/tsconfig.module.json
generated
vendored
Normal file
7
backend/node_modules/@aws-crypto/sha256-js/tsconfig.module.json
generated
vendored
Normal file
@@ -0,0 +1,7 @@
|
||||
{
|
||||
"extends": "./tsconfig",
|
||||
"compilerOptions": {
|
||||
"outDir": "build/module",
|
||||
"module": "esnext",
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user