Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/dms-codes/kriptografi-hill

Hill Cipher Encryption This Python script performs Hill cipher encryption on a given plaintext message using a user-defined key and matrix size 'm'.
https://github.com/dms-codes/kriptografi-hill

hill-cipher python

Last synced: 2 days ago
JSON representation

Hill Cipher Encryption This Python script performs Hill cipher encryption on a given plaintext message using a user-defined key and matrix size 'm'.

Awesome Lists containing this project

README

        

# Hill Cipher Encryption

This Python script performs Hill cipher encryption on a given plaintext message using a user-defined key and matrix size 'm'.

## Features

- Encrypts plaintext messages using the Hill cipher with a user-defined key and matrix size 'm'.
- Supports uppercase letters.
- Handles variable-sized plaintext and key input.

## Usage

1. Modify the `key`, `m`, and `plaintext` variables with the key and message you want to use.

2. Run the script by executing the following command in your terminal:

```bash
python your_script_name.py
```

3. The script will perform the encryption and print the ciphertext.

## Example

Suppose you have the following lines of code in your script:

```python
key = 'LIDH'
m = 2
plaintext = 'ES'
```

After running the script, you will see the following output:

```
Plaintext: ES
M = [[11 8]
[ 3 7]]
P = [[ 4 18]
[ 8 18]]
Ciphertext: SHYR
```

## License

This script is provided under the [MIT License](LICENSE).
```

Replace `"your_script_name.py"` with the actual name of your script. Feel free to customize the README.md file to include additional information or usage examples as needed for your project.