03 - Create a new CrypTool 2 Component (CrypTool 2 Development Series)
Автор: Cryptography for Everybody
Загружено: 2019-10-17
Просмотров: 2756
Описание:
#cryptology, #cryptography, #cryptanalysis
In this video, we show how to develop a new CrypTool 2 component from the scratch. You need: Visual Studio 2019 Community Edition, the CrypTool 2 component template for Visual Studio, and the CrypTool 2 source code. How to get all of these, please have a look at video 1 of this series ( • 01 - Installation of TortoiseSVN, VS2019, ... ) if not already done.
-------------------------
Hint: (update 01 oct 2020):
There is a problem when using the standard modulo operator of .net/C#. It may return negative numbers, which the math. operator does not. Therefore, we have to "fix" it using a method implementing the math. operator. So replace % in your code by the following method call:
private int Mod(int a, int b)
{
if(a GREATER_OR_EQUAL 0) // youtube does not allow the greater parenthesis symbol here;
{ return a % b; }
else
{ return ((a % b) + b) % b; }
}
-------------------------
Check list:
-------------------------
Step 1: Create new plugin project (using the plugin template in Visual Studio 2019)
Step 2: Rename plugin class file and rename settings class file
Step 3: Adapt plugin class attributes
Step 4: Create input properties (A, B, Input) and an output property (Output)
Step 5: Adapt and rename settings class : We need a way to switch between encryption and decryption action
Step 6: Implement Execution() method in plugin class (and needed helper methods)
Step 7: Compile and then test everything in CrypTool 2
Affine cipher definitions:
-------------------------
Encryption: C = (A * P + B) mod M
Decryption: P = (A^-1 * (C - B)) mod M
where
C is a ciphertext symbol as integer,
P is a plaintext symbol as integer,
M is the modulus,
A and B are integers (keys of the cipher),
A^-1 is the modular multiplicative inverse of A modulo M
In our case M = 26 since our alphabet is the Latin alphabet "ABCDEFGHIJKLMNOPQRSTUVWXYZ" which has length 26
Like what I do 😄? Help fuel my crypto obsession 🎓 — buy me a coffee here☕— thx: https://buymeacoffee.com/cryptography...
Повторяем попытку...
Доступные форматы для скачивания:
Скачать видео
-
Информация по загрузке: