加密二进制文件。 [英] Encrypting a binary file.

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

问题描述

是否可以使用C ++读取二进制文件,如.exe / .jpg文件,并使用一些简单的算法对其进行加密。



真正的问题是如何将整个.exe或jpg文件读入1维数组并进行操作。

Is it possible to read a binary file such as .exe / .jpg files using C++ and encrypt it using some simple algorithm.

The real question is how to read an entire .exe or jpg file into 1 dimensional array and manipulate it.

推荐答案

简单的答案是是。您可以加密任何类型的文件,而.exe / .dll只是另一种类型的文件。你必须要注意文件访问和所有权等明显的事情,但它可以毫无困难地完成。您通常无法写入当前正在使用的系统文件或文件。
The simple answer is "yes". You can encrypt any type of file, and a .exe/.dll is just another type of file. You have to beware of obvious things like file access and ownership but it can be done without significant trouble. You typically won''t be able to write to system files or files that are currently in use.


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

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