加密解密 [英] encrypt decrypt finls

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

问题描述

大家好
我希望你一切都好
我正在开发的程序取决于套接字编程
那是跨平台的
该程序在计算机之间发送文件
所以现在我想加密我的文件并在目标位置解密
....
我对加密和解密视而不见
你能说我怎么样吗?
现在我正在搜索这个,也许这取决于md5以及如何\ ??
还有qt中的源代码??
如果我使用公共/私钥,我是否可以同时使用linux和Windows ...
以及您认为对我推荐和建议的其他内容,我很高兴听到这个消息
谢谢大家

hi every body
i hope you be fine
i am working on a program depends on socket programming
that is cross platform
and this program send file between come computers
so now i wanna encrypt my files and in destination decrypt that
....
i am blind about encrypt and decryptions
can you say me how is it??
now i am searching about this maybe this is depends on md5 and how\??
and source code in qt is there??
if i use puclic /private keys can i use linux and windows both...
and other thing you think recommend and advice to me i am glad to hear that
thank you all

推荐答案

MD5不是加密算法-它是哈希算法.如果使用它加密"数据,则将无法解密数据,因为哈希算法不可逆. (并且MD5还是不建议用于新应用程序,因为它被认为是损坏的".).

您可以使用公钥/私钥加密,但是对于点对点DES可能是一个更好的选择. C ++ DES库是免费提供的,您可以在Google上轻松找到自己喜欢的库.
MD5 is not an encryption algorithm - it is a hashing algorithm. If you use it to "encrypt" your data, you will not be able to decrypt it as hashing algorithms are not reversible. (And MD5 is not recommended for new applications anyway, because it is considered "broken").

You could use public / private key encryption, but for point - to point DES might be a better choice. C++ DES libraries are freely available, and you should find one you like quite easily with Google.


您可以使用,例如AES.可以在这里找到C源代码:密码学-256位密码" [
You may use, for instance AES. The C source code maybe found here: "Cryptography - 256 bit ciphers"[^] (I used it without problems).


如果此文件或数据是通过网络传输,我建议使用SSL,使用OpenSSL是免费的跨平台库: ^ ].

即使如此,您也不必从头开始.由于您使用的是QT,请使用它为您提供的使用QtSSLSocket保护网络 [
If this file or data is transferred via a network, I''d recommend using SSL, using OpenSSL witch is free and cross-platform library: SSL Programming Tutorial[^].

Even though, you don''t have to start form scratch. Since you use QT, use what it provides you Secure Networking with QtSSLSocket[^].


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

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