RSA文本加密/解密工具 [英] RSA Text Encryption/Decryption Tool

查看:234
本文介绍了RSA文本加密/解密工具的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

您好我一直在寻找一种方法来使用RSA加密来加密文本,但也有一个加密密钥可以显示,然后用于解密文本。我没有找到满足我需求的例子,请尽可能帮助!



需要什么:



1.点击按钮生成RSA加密密钥(加密密钥必须能够在文本框中显示,此密钥必须能够被其他人用来解密文本!)



2.从中获取RSA加密密钥解密时的文本框(换句话说,用户可以输入已由某人发送的密钥,他们可以使用此密钥解密文本)



3。显示文本框的输出和加密/解密。



任何帮助都将不胜感激!



谢谢

Hi i have been looking for a way to use RSA encryption to encrypt text but also have a encryption key that can be displayed and later used to decrypt the text. I haven't found an example which meets my needs please help if you can!

What is needed:

1. Generate a RSA encryption key on button click(Encryption key must be able to be displayed in a textbox, Also this key must be able to be used by others to decrypt the text!)

2. Grab the RSA encrption key from a textbox on decryption (so in other words the user can input a key that has been sent by someone and they can use this key to decrypt the text)

3. Display the output of and encryption/decryption to a textbox.

Any help would be appreciated!

Thank you

推荐答案

这不仅是不可能的,根本没有意义。有两个键,这个想法完全不同。你不能写出对你能做什么和想要达到的目标没有任何线索的要求。从这里开始: http://en.wikipedia.org/wiki/Public-key_cryptography [ ^ ]。



小心:如果你注意阅读它,它应该把你的大脑翻出来。 :-)



-SA
Not only this is impossible, it makes no sense at all. There are two keys, and the idea is radically different. You cannot write requirements having no clue on what you can and want to achieve. Start here: http://en.wikipedia.org/wiki/Public-key_cryptography[^].

Be careful: if you read it with attention, it should turn your brain inside out. :-)

—SA


RSA是非常 特定类型的加密。它通常不用于加密数据块,实际上加密数据非常差 - 你只能使用RSA加密一个非常小的块,而且计算成本非常高。你永远不会像使用对称加密算法那样费心去使用它。 RSA(以及它的老朋友DSA)通常用于安全消息身份验证(创建数字签名)或安全地交换对称密钥以传输大量数据。



要求像你这样的问题,大致相当于问而不是我的卡车,我想使用Mini来运输集装箱或如何让我的激光喷射机以3d打印 - 问题本身就是从根本上说是有缺陷的 - 所以我希望你能理解为什么人们在不诉诸讽刺的情况下努力回答。



但是我想指出谢尔盖确实为你指出了一个非常好的资源,并在他的信息结尾添加了一个大笑脸所以我不会把它当作讽刺。
RSA is a very specific type of encryption. It is not normally used to encrypt blocks of data, it is in fact very poor at encrypting data - you can only encrypt a very small block using RSA, and it is computationally very expensive. You would never bother to use it like you would a symmetrical encryption algorithm. RSA (and it's older friend DSA) is normally used for secure message authentication (creating digital signatures) or to securely exchange symmetric keys for transferring larger amounts of data.

Asking the question as you did, was roughly equivalent to asking "instead of my truck, I'd like to use a Mini to transport shipping containers" or "how do I get my laser-jet to print in 3d" - the question itself is fundamentally flawed - so I hope you can understand why people are struggling to answer without resorting to sarcasm.

However I would like to point out that Sergey did point you to a very good resource, and added a big smiley to the end of his message so I wouldn't take that as sarcasm.


这篇关于RSA文本加密/解密工具的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆