From b7e69df12c90719458d3e0c0233c34aa0be8c166 Mon Sep 17 00:00:00 2001 From: ENGO150 Date: Sat, 25 Jan 2025 15:45:48 +0100 Subject: [PATCH] created doc for why2_decrypt_text --- .../core/decrypter/why2_decrypt_text.md | 40 +++++++++++++++++++ docs/functions/index.md | 12 ++++-- 2 files changed, 49 insertions(+), 3 deletions(-) create mode 100644 docs/functions/core/decrypter/why2_decrypt_text.md diff --git a/docs/functions/core/decrypter/why2_decrypt_text.md b/docs/functions/core/decrypter/why2_decrypt_text.md new file mode 100644 index 0000000..18eb678 --- /dev/null +++ b/docs/functions/core/decrypter/why2_decrypt_text.md @@ -0,0 +1,40 @@ + + +# why2_decrypt_text + +## Parameters + +| Identifier | Data type | +| ---------- | --------- | +| `text` | `char *` | +| `key` | `char *` | + +## Attributes + +| | | +| ------------------ | --------------------------------------------------------------------- | +| **Return type** | [`why2_output_flags`](../../../../types/core/flags/why2_output_flags) | +| **Header comment** | `TEXT from WILL BE DECRYPTED WITH KEY AND RETURNED` | +| **Added in commit** | [`d9a99b985105b99b3ef237597f8ea91a751b89f1`](https://github.com/ENGO150/WHY2/commit/d9a99b985105b99b3ef237597f8ea91a751b89f1) | + +## Description + +Function removes padding (if present) from `text` using `key`, decrypts and returns output in [`why2_output_flags`](../../../../types/core/flags/why2_output_flags) among with some run data. + +Encryption/Decryption functions are using settings from [`why2_input_flags`](../../../../types/core/flags/why2_input_flags). You can set those using [`why2_set_flags`](../../../../functions/core/flags/why2_set_flags). \ No newline at end of file diff --git a/docs/functions/index.md b/docs/functions/index.md index 26afce6..f6a1476 100644 --- a/docs/functions/index.md +++ b/docs/functions/index.md @@ -22,15 +22,21 @@ You can find documentation for every *public* function of WHY2 below. ## Core -### Crypto.h +### Crypto -| Function | Description | -| ------------------------------------------------------- | ------------------------------------------------ | +| Function | Description | +| ---------------------------------------------------- | ------------------------------------------------ | | [`why2_sum_segment`](./core/crypto/why2_sum_segment) | Calculate SUM++ for input; Used for padding seed | | [`why2_random`](./core/crypto/why2_random) | Write crypto-secure random number into dest | | [`why2_seed_random`](./core/crypto/why2_seed_random) | Seed why2_seeded_random output | | [`why2_seeded_random`](./core/crypto/why2_seeded_random) | GENERATE RANDOM NUMBER BASED ON SEED PASSED IN why2_seed_random | +### Decrypter + +| Function | Description | +| --------------------------------------------------------- | ------------------------------------------------- | +| [`why2_decrypt_text`](./core/decrypter/why2_decrypt_text) | Text from Will be decrypter with key and returned | + ## Logger ## Chat \ No newline at end of file