Simple Matlab Code For Image Encryption and Decryption.

Can someone please post a simple matlab code for image encryption/decryption. Its urgent. Thank you. :)

7 件のコメント

fati gh
fati gh 2014 年 5 月 19 日
i need to .please send for me
Image Analyst
Image Analyst 2014 年 5 月 19 日
She downloaded something from the File Exchange. You can do that yourself, you don't need her to send it to you.
shikha pandey
shikha pandey 2020 年 4 月 25 日
please provide code for image encrption
Dhayanithi Govindasamy
Dhayanithi Govindasamy 2020 年 11 月 28 日
編集済み: Walter Roberson 2020 年 11 月 28 日
As far as the concern is about the images, so we are taking the values from 0 to 255.
First of all have to read an image which you want to encrypt and decrypt.
For example:
image = imread("Image.jpg");
image = double(lena);
[steps removed due to US law]
This will give you an encrpted image.
Walter Roberson
Walter Roberson 2020 年 11 月 28 日
Sorry, Dhayanithi Govindasamy, the steps you posted could easily have been extended past 56 bits key space, and so we are not permitted to host that discussion here due to US law.
Walter Roberson
Walter Roberson 2020 年 11 月 28 日
Images are not always 0 to 255. For example CT scan images are routinely int16 values, -32768 to +32767

サインインしてコメントする。

 採用された回答

Image Analyst
Image Analyst 2014 年 4 月 13 日
編集済み: Image Analyst 2014 年 4 月 13 日

0 投票

I'm guessing you did not do a search of the File Exchange or you would not be asking this. Please click on this link: http://www.mathworks.com/matlabcentral/fileexchange/index?utf8=%E2%9C%93&term=encryption

7 件のコメント

Niharika
Niharika 2014 年 4 月 13 日
Thanks a lot :)
Niharika
Niharika 2014 年 4 月 13 日
Error using picCrypt (line 63) You must enter the correct number of parameters ------------- This is the output i keep getting. I'm new to matlab. Can you please help out?
Image Analyst
Image Analyst 2014 年 4 月 13 日
That's not my code and I have no idea what code you're running. Can you ask the author? If it's your code, then attach your m-file with the paper clip icon.
Manpreet
Manpreet 2015 年 2 月 27 日
I too is Implementing the Same Code and I am getting the Same Problem.Error using picCrypt (line 63) You must enter the correct number of parameters ------------- This is the output i keep getting. I'm new to matlab. Can you please help out?.....................How to Tackle this.........Please Email the Solution to my Email sany26.com@gmail.com.
Image Analyst
Image Analyst 2015 年 2 月 27 日
Contact the author or else use the debugger. I don't have the code and don't need it, so I have no plans on downloading it and running the debugger for you. I'd guess from the error message that you're not entering all the parameters that it wants.
Abdiaziz Hussein
Abdiaziz Hussein 2019 年 11 月 10 日
I need a algorithm written in Matlab, for a Elgamal encryption which can encrypt and decrypt data stream of 32 words, with a key which has a modulus of 1024 vits

サインインしてコメントする。

その他の回答 (2 件)

Namitha H.S Gowda
Namitha H.S Gowda 2018 年 3 月 25 日

0 投票

Can someone please post a simple matlab code for image encryption/decryption

5 件のコメント

John D'Errico
John D'Errico 2018 年 3 月 25 日
NO. We are not allowed to do that.
Walter Roberson
Walter Roberson 2018 年 3 月 26 日
There is only one image encryption algorithm that we can post and still satisfy the law of USA:
function encrypted_image = encrypt_image(input_image)
encrypted_image = input_image;
function decrypted_image = decrypt_image(encrypted_image)
decrypted_image = encrypted_image;
Everything else is pretty much forbidden without special permission of a USA government department.
Walter Roberson
Walter Roberson 2018 年 11 月 12 日
Under international treaty , encryption is considered a munition, a weapon . Encryption code and discussion of encryption algorithms are controlled by the government of the United States . In order to meet free speech laws , the compromise is that every single person who posts encryption code must notify the Department of Commerce immediately after posting it, and that discussion of encryption is permitted only with the preapproval of the Department .
Formally speaking , preapproval is not required as long as the algorithm is one that cannot be modified by the user to have aa key space of more than 56 bits, but the only algorithm that meets that requirement is null encryption which leaves the message completely unchanged . For example ROT13 is a simple example of a Caeser Cypher which in turn is a simple example of a Vigenere Cypher which can be trivially extended past 56 bits.
Image Analyst
Image Analyst 2018 年 11 月 13 日
Try a search for ITAR encryption rules You'll find lots of information
Even US universities need to get approval to do research into advancing the state of the art in encryption. Note that encryption is different than encoding, like encoding a video into a binary file.
Walter Roberson
Walter Roberson 2018 年 11 月 13 日
It is a frustrating restriction, and often makes little sense, but it is the law of the USA.
Another note: authentication is considered to be different than encryption. So something like a well-hidden watermark to verify copyright is legal. The technologies for watermarking are essentially the same as steganography (hiding messages), so the legal boundaries are far from clear.

サインインしてコメントする。

arun anoop m
arun anoop m 2019 年 8 月 5 日
編集済み: Walter Roberson 2019 年 8 月 16 日

0 投票

2 件のコメント

sana kadim
sana kadim 2019 年 8 月 16 日
can you tell me the algorithm who can i do?
siraqsana@gmail.com
Walter Roberson
Walter Roberson 2019 年 8 月 16 日
Any algorithm that can encrypt binary streams can be used to encrypt images.
Discussion of all the image encryption algorithms and their benefits and tradeoffs is beyond the scope of this resource.

サインインしてコメントする。

カテゴリ

ヘルプ センター および File ExchangeEncryption / Cryptography についてさらに検索

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by