简体   繁体   English

给定用户名和密码,如何在Windows上使用Perl将文件从一台计算机复制到另一台计算机

[英]Given username and password, how do I copy files from one machine to another using perl on windows

I main issue is of authentication, then the actual copying of files from once machine to another. 我的主要问题是身份验证,然后将文件从一台计算机实际复制到另一台计算机。 By the way both these machines are on the same network ie connected through LAN. 顺便说一下,这两个机器都在同一网络上,即通过LAN连接。

Is there any perl function to do this. 是否有任何perl函数可以执行此操作。 Plus, I wanted to make sure if authentication is absolutely necessary. 另外,我想确保验证是否绝对必要。

If they are two windows machines or if both have samba or CIFS shares--below or at where you want to copy from/to, then you can just map or mount one onto the other machine and copy that way. 如果它们是两台Windows计算机,或者两者都具有sambaCIFS共享(在下面或要在其中复制/复制的位置),则可以其中一个映射挂载到另一台计算机上,然后进行复制。 The security depends on your network and how the shares were set up. 安全性取决于您的网络以及共享的设置方式。

Also, in this vein, given the hostname or ip you might be able to use a UNC path: 同样,按照这种方式,给定主机名或ip,您也许可以使用UNC路径:

\\remotehost\c$\Users\Me\Documents -- depending on your level of access

Otherwise there is Net::FTP if you don't need SSL and Net::SCP / SFTP if you do. 否则,如果您不需要SSL,则有Net::FTP如果不需要,则有Net::SCP / SFTP You can often script these to do directory copies. 您通常可以使用脚本编写目录副本。

暂无
暂无

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 如何使用Java将文件从一台Windows计算机复制到另一台Windows计算机文件夹 - How do i copy a file from one windows machine to other windows machine folder using java 如何使用批处理脚本将文件从一台Windows计算机复制到特定驱动器中的另一台Windows计算机? - How to copy the file from one windows machine to another windows machine in a particular drive using batch script? 如何将数据从一个Windows应用程序复制到另一个? - How do I copy data from one windows app to another? 如何将4个最新文件从受密码保护的在线目录复制到另一个目录? - How do I copy the 4 latest files from a password-protected online directory to another directory? 如何将文件从一台Windows计算机复制到另一台Windows计算机? - How to copy a file from one windows machine to other windows machine? 如何使用scp将文件从远程计算机(运行Linux)复制到Windows计算机? - How do I copy files from a remote computer (running Linux) to my Windows computer using scp? SSH 通过 shell 脚本使用用户名和密码到远程 Windows 机器 - SSH to remote Windows machine using username and password through shell script 使用Windows命令将非xml文件从一个目录复制到另一个目录 - Copy non xml files from one directory to another using windows command Windows脚本可将X个文件从一个文件夹复制到另一个文件夹 - Windows script to Copy X number of files from one folder to another 使用Java将文件从本地窗口机器复制到远程Windows机器 - Copy files from local window machine to remote windows machine using java
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM