2

Our organisation uses TeamViewer (v10). I haven't found any way to automate or batch process tasks across multiple machines (eg copy same file to many, and ideally execute). Currently I have to do it one-by-one.

I've recently discovered that TeamViewer supports a "VPN" connection mode. This sets up a direct IP connection between the two machines (host and client). However it's not true VPN in that it doesn't allow access to the entire remote network.

Each time a VPN session is created it uses DHCP IP addresses, handed out by a TeamViewer server (7.0.0.1). Each client adapter is set to dynamic. Furthermore, when I override the settings and set a static IP address, it is not shown in the dialog box. The same 7.x.x.x address is shown, even though the local network adapter is set to 192.x.x.x.

TeamViewer VPN dialog

This all works for a graphical interactive session. I would like to wrap this up in a script for deployment tasks.

The VPN can be initiated from the command line:

TeamViewer.exe -i <id> --Password <password> -m vpn

https://community.teamviewer.com/t5/Knowledge-Base/Are-there-parameters-to-start-TeamViewer/ta-p/4135

This allows me to create a VPN session to the remote machine. The same dialog box is opened, but the command immediately returns with no text output. I can find no way to either retrieve the IP details automatically, nor to set them statically.

Has anyone succeeded in scripting TeamViewer VPN?

Ian
  • 160
  • 1
  • 9
  • It’s not clear what you are trying to accomplish. If it’s a single organization then use what Microsoft gave us - group policy. If you’re a third party IT company then use an RMM tool or SCCM, or an MDM. Why are you trying to hack together something that wasn’t designed to do what you want to do? It’s not professional. – Appleoddity Nov 30 '17 at 03:50
  • @Appleoddity I have roughly 30 PCs distributed around the world, in remote locations (intermittent internet), using internet access we have no control over (eg NAT), with no domain controller. We already use TeamViewer for remote desktop access. Rather than me having to set up new network conditions, servers, or software, I want to know if it's possible to use what I have. – Ian Nov 30 '17 at 04:04

1 Answers1

0

Surely you've already found a way to do this... but if not, you can use this UI automation package called TestStack White. I've used it to automate file transfer between computers through teamviewer.

https://teststackwhite.readthedocs.io/en/latest/

Use this in conjunction with UIspy (or inspect.exe if you have that instead. both accomplish the same goal)

Keep in mind this only works for straight-up file transfer (at least, I haven't tried to go any further with it.)

  • 1
    TeamViewer 14 was recently released with [https://community.teamviewer.com/t5/Community-Blog/Script-Execution-Solution-in-TeamViewer-14/ba-p/45997](Remote Script Execution). We upgraded and it is pretty good! – Ian Jun 19 '19 at 23:29