如何将文本数据从一台计算机传输到另一台计算机 [英] How can I transfer textual data from one computer to another

查看:138
本文介绍了如何将文本数据从一台计算机传输到另一台计算机的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在开展一个关于加密和解密的大学项目。我正面临一个问题。想法是从计算机1上的用户输入数据并在其上加密并将该数据发送到计算机2但我不知道如何在软件内部传输它,因为我不希望用户手动进行复制粘贴我希望软件本身获取这些加密数据并解密。



我尝试过:



i没有尝试任何东西,因为我缺乏执行此功能的知识。

i am working on a college project on encryption and decryption. i am facing a problem. The idea is to input data from user on computer 1 and encrypt it on it and send this data to computer 2 but i don't know ways to transfer it inside the software since i don't want the user to manually do the copy paste i want the software itself to fetch this encrypted data and decrypt it.

What I have tried:

i have not tried anything since i lack the knowledge to perform this function.

推荐答案

就像理查德在对你的问题的评论中提到的那样,您可以使用套接字建立网络连接并将文件发送到该计算机。加密邮件后,请ping设备并请求设备发送数据。建立连接后,开始发送数据。然后,在另一边,接收数据并在那里解密。



首先,它比听起来更简单,唯一的补充是 TcpListener TcpClient 两个应用程序都可以通过网络进行通信的对象。



我写了一篇文章,涵盖了你可能想知道的所有内容,然后继续创建这样的应用程序,可以在网络上进行通信,在这里查看一下,使用本机.NET TCP库创建服务器/客户端应用程序 [ ^ ]。然后你可以将数据从一台机器发送到另一台机器。
Just the way Richard mentions in his comment to your question, you can use sockets to establish a network connection and send the file over to that machine. Once you have encrypted the message, ping the device and request it to allow your device to send the data. Once the connection has been established, start sending the data. Then, on the other side, receive the data and decrypt it there.

Primarily, it is simpler than it sounds, the only addition is of TcpListener and TcpClient objects that would both applications to communicate over the network.

I wrote just the article that covers everything you may want to know before proceeding with creation of such applications, that can communicate on the network, have a look at it here, Creating a server/client application using native .NET TCP library[^]. Then you can send the data from one machine to another.


你需要多长时间才能完成这个项目?首先获取基本功能。加密到文件,手动将其复制到另一台计算机,然后解密。当你完成这项任务时,你会尝试扩展它。当你打开它时,让核心功能工作比让它不起作用更好,因为你花了所有的时间来尝试让其他工作与项目没有任何关系,你想要的功能是需要花费大量的时间和资源才能开始工作。
How long do you have to work on this project? Get the base functionality down first. Encrypt to a file, manually copy it over to the other machine, and decrypt it. When you get this done ONLY THEN do you try to expand on it. It's better to have the core functionality working when you turn it in than to have it not working because you spent all of your time trying to get something else working that doesn't have anything to do with the project, and the functionality you want is going to take a lot of time and resources to get working.


这篇关于如何将文本数据从一台计算机传输到另一台计算机的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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