From 61fb85601c46dc9ae5d7ae5a681149313cb4f71c Mon Sep 17 00:00:00 2001 From: Woose Date: Fri, 13 Dec 2024 10:43:13 +0300 Subject: [PATCH] created docstring --- .vscode/settings.json | 53 +++++++++++++++++++++++++++++++++++++++++++ Encryption.cpp | 11 +++++++++ README.md | 8 +++++-- 3 files changed, 70 insertions(+), 2 deletions(-) create mode 100644 .vscode/settings.json diff --git a/.vscode/settings.json b/.vscode/settings.json new file mode 100644 index 0000000..f1790b6 --- /dev/null +++ b/.vscode/settings.json @@ -0,0 +1,53 @@ +{ + "files.associations": { + "iomanip": "cpp", + "array": "cpp", + "atomic": "cpp", + "bit": "cpp", + "*.tcc": "cpp", + "cctype": "cpp", + "clocale": "cpp", + "cmath": "cpp", + "compare": "cpp", + "concepts": "cpp", + "cstdarg": "cpp", + "cstddef": "cpp", + "cstdint": "cpp", + "cstdio": "cpp", + "cstdlib": "cpp", + "ctime": "cpp", + "cwchar": "cpp", + "cwctype": "cpp", + "deque": "cpp", + "string": "cpp", + "unordered_map": "cpp", + "vector": "cpp", + "exception": "cpp", + "algorithm": "cpp", + "functional": "cpp", + "iterator": "cpp", + "memory": "cpp", + "memory_resource": "cpp", + "numeric": "cpp", + "optional": "cpp", + "random": "cpp", + "string_view": "cpp", + "system_error": "cpp", + "tuple": "cpp", + "type_traits": "cpp", + "utility": "cpp", + "initializer_list": "cpp", + "iosfwd": "cpp", + "iostream": "cpp", + "istream": "cpp", + "limits": "cpp", + "new": "cpp", + "numbers": "cpp", + "ostream": "cpp", + "sstream": "cpp", + "stdexcept": "cpp", + "streambuf": "cpp", + "cinttypes": "cpp", + "typeinfo": "cpp" + } +} \ No newline at end of file diff --git a/Encryption.cpp b/Encryption.cpp index c367dea..146e9e6 100644 --- a/Encryption.cpp +++ b/Encryption.cpp @@ -1,3 +1,14 @@ +/** + * @brief This C++ program is designed to compute the SHA-256 hash of a user-provided string. + * Here's a breakdown of how it works: + * Prompts the user to enter a string. + * Reads the input string from the standard input (using getline). + * Calls the SHA256 function with the user-provided string and prints the resulting SHA-256 hash. + * + * @author Yavuz Sava (woose) + * @date 13/12/2024 + */ + #include #include #include diff --git a/README.md b/README.md index ea8b942..1381af6 100644 --- a/README.md +++ b/README.md @@ -1,7 +1,11 @@ # Sha256EncryptionInCpp -Sha256 encryption program written in C++ +Sha256 encryption program written in C++. This C++ program is designed to compute the SHA-256 hash of a user-provided string. +Here's a breakdown of how it works: + 1. Prompts the user to enter a string. + 2. Reads the input string from the standard input (using getline). + 3. Calls the SHA256 function with the user-provided string and prints the resulting SHA-256 hash. - Usage example: +Usage example: cd "/VSCodeLibrary/C++/" && g++ Encryption.cpp -o Encryption -lssl -lcrypto && "/VSCodeLibrary/C++/"Encryption Enter a string to encrypt: \ No newline at end of file