{"id":19190289,"url":"https://github.com/seigtm/strategyfileencrypter","last_synced_at":"2025-04-20T07:34:22.325Z","repository":{"id":52784375,"uuid":"358978626","full_name":"seigtm/StrategyFileEncrypter","owner":"seigtm","description":"An example of text files encryption using the strategy design pattern.","archived":false,"fork":false,"pushed_at":"2021-06-17T18:47:38.000Z","size":9,"stargazers_count":5,"open_issues_count":0,"forks_count":1,"subscribers_count":1,"default_branch":"main","last_synced_at":"2023-03-08T19:16:12.345Z","etag":null,"topics":["cipher","cipher-algorithms","encrypt","encryption","encryption-algorithms","encryption-decryption","encryption-strategies","file-encrypter","file-encryption","files-encrypter","files-encryption","hierarchy","strategy","strategy-design-pattern","strategy-pattern","text-cryptography","text-encryption"],"latest_commit_sha":null,"homepage":"","language":"C++","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/seigtm.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2021-04-17T20:44:34.000Z","updated_at":"2022-10-11T00:30:10.000Z","dependencies_parsed_at":"2022-08-22T06:50:37.354Z","dependency_job_id":null,"html_url":"https://github.com/seigtm/StrategyFileEncrypter","commit_stats":null,"previous_names":[],"tags_count":null,"template":null,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/seigtm%2FStrategyFileEncrypter","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/seigtm%2FStrategyFileEncrypter/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/seigtm%2FStrategyFileEncrypter/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/seigtm%2FStrategyFileEncrypter/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/seigtm","download_url":"https://codeload.github.com/seigtm/StrategyFileEncrypter/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":223822729,"owners_count":17208917,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["cipher","cipher-algorithms","encrypt","encryption","encryption-algorithms","encryption-decryption","encryption-strategies","file-encrypter","file-encryption","files-encrypter","files-encryption","hierarchy","strategy","strategy-design-pattern","strategy-pattern","text-cryptography","text-encryption"],"created_at":"2024-11-09T11:33:42.679Z","updated_at":"2024-11-09T11:33:43.226Z","avatar_url":"https://github.com/seigtm.png","language":"C++","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Text files encryption using strategy design pattern in C++.\n\nThis source code is a template of using the **strategy** design pattern for text files encryption in C++.  \nThis project is a homework from my college programming teacher.\n\n## Problem statement:\n\n\u003e Develop the program for encrypting text documents.  \n\u003e The user enters a string containing the path to the text file (\"C:/example.txt\").  \n\u003e After that, he enters a number from 1 to 3 to clarify the text encryption method.  \n\u003e After the selected algorithm works, the encrypted text is saved to another file (\"C:/example_ciphered.txt\").  \n\u003e Develop the console application that implements the described functionality and contains a hierarchy of encryption classes.  \n\u003e Justify the selected class hierarchy and the selected design pattern.\n\n## Implementation:\n\nA basic virtual class for std::string encryption strategies:\n\n```cpp\nclass EncryptionStrategy\n{\npublic:\n    virtual std::string encrypt(const std::string \u0026text, const std::string \u0026key = \"\") = 0;\n    virtual std::string decrypt(const std::string \u0026text, const std::string \u0026key = \"\") = 0;\n};\n```\n\nConcrete encryption strategy using XOR:\n\n```cpp\nclass XOREncryptionStrategy : public EncryptionStrategy ...\n```\n\nConcrete encryption strategy using Caesar:\n\n```cpp\nclass CaesarEncryptionStrategy : public EncryptionStrategy ...\n```\n\nConcrete encryption strategy using Binary code:\n\n```cpp\nclass BinaryEncryptionStrategy : public EncryptionStrategy ...\n```\n\nInterface for file encryption using encryption strategies:\n\n```cpp\nclass IFileEncryptor ...\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fseigtm%2Fstrategyfileencrypter","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fseigtm%2Fstrategyfileencrypter","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fseigtm%2Fstrategyfileencrypter/lists"}