Menu

NAT problem when sending files

Help
Peter
2014-11-14
2014-11-19
  • Peter

    Peter - 2014-11-14

    Hallo,
    I want to send clips between 2 computers on distant locations.
    Both computers are connected to the internet through NAT routers.
    I have made port forwardings for port 23443 on both routers.
    I can send clips using the public router-IP of the receiving computer.

    I can also send files, but pasting these files fails.
    When pasting, the receiving computer tries to connect to the sending computer,
    using the private IP of the sending computer.
    This fails, as both computers are only reachable over the public IP of their router, there is no VPN Connection.

    How can I achieve, that Ditto uses the public IP of the sending computer to download the file?

    Thanks,
    Peter

     
  • Maloney

    Maloney - 2014-11-15

    Currently i don't think this will be possible as ditto sends the primary ip (first ip according to windows) and machine name to the remote ditto. Then on file paste it connects back to that ip, witch is probably 192.168.x.x or something similar rather than your public ip.

    I can think of a few different changes to get around this.

    1) Add settings to force a specific ip to be sent with a clip rather than getting it from windows. You can enter your public ip.

    2) Add setting to prompt for the ip address if it fails or always prompt

    Do you have any other ideas? Prefer either of these? I'm probably leaning to the first one.

    scott

     
  • Peter

    Peter - 2014-11-19

    Hallo Scott,

    I would also prefer 1), if I can also force URLs to be sent with the clip, as one of my
    PCs has a dynamic public IP and is only reachable with a dyndns hostname.

    Other ideas:
    3) When Ditto receives a clip, it writes the source IP of the incoming TCP connection to
    the database, and uses this IP to request the file.

    4) optionally send the file immediately, together with the clip in the same TCP connection.

    Another feature request:
    Is it possible to play a sound file only when a clip is received over network?

    Ditto really is a great software! Especially the network function rocks.
    Thx for your great work,
    Peter

     
  • Gary Fowler

    Gary Fowler - 2017-04-26

    Problem:

    Syncing clipboards between two computers when the user only controls one side's infrastructure (firewalls, routers etc.). TCP port 23443 is not allowed through the firewall at one location.

    Solution:

    Ditto makes a connection from Computer A to Computer B's Public IP on a configurable port (not just 23443).
    Computer A and Computer B use the established TCP socket to push and pull clipboard to/from each other.

    I further propose that Ditto implement a security/encryption layer similiar to SSH.
    Dialog pops up on each side;

    ComputerB - A Ditto Agent on BLAH at IP address 192.0.44.7 is attempting to connect with Host Key 76AC:9FBD:3B1C. Do you Accept [Yes and Save Key] [No / Refuse]

    ComputerA - The Ditto Agent on THING2 at IP address 200.200.200.200 has presented Host Key 96AC:9ABF:8833. Do you Accept [Yes and Save Key] [No / Refuse]

    Once connected, you could have a dialog to configure what gets pushed between the two Ditto CP managers.

    This solution would allow Ditto to work when 23443 is not allowed to exit one infrastructure.

    Another posible solution is to use SSH as a tunneling service. Instead of just pure TCP.. have an option to Proxy/Tunnel via SSH. Add SSH code or Have some code that uses Putty or other tool to initiate a connection to an SSH server with Local and/or Remote port forwarding.


    Problem:

    Syncing clipboards boards between two computers when the user does not control either side's infrastructure (firewalls, routers etc.).

    Solution:

    Use an intermediary service such as Owncloud (either natively or via WebDAV ), Dropbox etc.

     

Log in to post a comment.