Score:0

Internet file transfer command

in flag

I am doing research and need to transfer a file between home and office via the Internet. It is easy to do that with some software such as AnyDesk. Since I want to do file transfer by a bash file in Linux, I am looking for a command such as "scp" or at least a simple software that provides facilities and I can do it via a bash script.

As far as I know, it is not possible to do that by scp command if you have no public IP address. Any help is appreciated.

waltinator avatar
it flag
Read https://askubuntu.com/help/how-to-ask
pasman pasmański avatar
mx flag
What release of Ubuntu you use ?
waltinator avatar
it flag
Use a file sharing service. Many offer several GB for free.
Score:1
jp flag

A very simple tool which handles the ”not knowing IPs” situation seamlessly (uses temporary passwords for transfer authentication) and gzips the transfer is portal.

(NOTE: I wrote this!)

How to use it

Alice wants to send <folder1> and <file.txt> to Bob, who can be behind the same NAT for direct transfer or anywhere on the internet for relayed transfer. Portal will use direct transfer if it's possible.

Alice initializes the file transfer by executing the following in her shell:

portal send <folder1> <file.txt>

This outputs a temporary password, which Alice communicates to Bob via some other secure channel.

# the output of the send command, use this password to receive the files 
> 1-supernova-gamma-ray

Bob executes the following command to receive folder1 and file.txt:

portal receive 1-supernova-gamma-ray

The file transfer will now begin!

Pros

  • e2e encryption
  • fast gzip (de)compression
  • simple protocol aids transfer speed
  • handles folders of any sort and depth
  • direct communication if ports are open or behind same NAT

Cons

  • does not do NAT traversal so transfer goes through a relay if direct communication cannot be established
  • it's a new tool so it is untried in different systems and might have weird bugs
ru flag
@Greenonline if you believe the person is a cross site spammer you need to contact staff using the Contact Us option at the bottom of the page. Ask Ubuntu moderators only operate within the purview of Ask ubuntu.
Zino avatar
jp flag
I don't understand what @Greenonline is after. I sought after questions that looked for something like this tool I've recently created, and have answered them by providing a legitmate alternative. What about that is spam?
Greenonline avatar
us flag
@ThomasWard - The issue with the *original* post(s) was that no affiliation was declared - hence the *probable* spam red flag. I then also saw the same post in various review queues across three sites. Upon the third review, I realised that something was up, hence the flag. However, as Zino has **now** declared his affiliation, the spam issue no longer applies. So, Zino, if you edit your other posts (on the other two sites) in the same way, by declaring your affiliation, you should then be able to flag them to be undeleted by the moderators. I hope that makes matters clearer... Good luck :-)
Zino avatar
jp flag
Ah, I see. I'll do that, thank you.
Score:0
cn flag

There are many possibilities to do that.

I would do that with rsync.

rsync -a localhost:source targethost:destination

Here is a little description of rsync. https://www.tecmint.com/rsync-local-remote-file-synchronization-commands/

Mahdi avatar
in flag
Thanks for your comment. But it is not helpful to my problem because you need to know both source and destination IP addresses (I have no public IP). There should be a utility that makes a bridge and connects both PCs. I am looking for that utility.
Thomas Aichinger avatar
cn flag
Some people would call that VPN
mangohost

Post an answer

Most people don’t grasp that asking a lot of questions unlocks learning and improves interpersonal bonding. In Alison’s studies, for example, though people could accurately recall how many questions had been asked in their conversations, they didn’t intuit the link between questions and liking. Across four studies, in which participants were engaged in conversations themselves or read transcripts of others’ conversations, people tended not to realize that question asking would influence—or had influenced—the level of amity between the conversationalists.