[Okta Webinar] Learn how to a build a cloud-first strategyRegister Now


Adding client routes to pptp vpn

Posted on 2012-09-15
Medium Priority
Last Modified: 2013-12-02

Using Windows SBS 2011, RRAS with PPTP for vpn connections.
We have two networks on different segments, both can be accessed from the server (this is handled by the router).

When a remote user connects using pptp to the server, he can only access the network that the server is connected to, unless executing locally the "route add .....etc'" command which tells the user's local computer to route packets for the second network to the same pptp interface.

We can however use TUNNEL mode to route everything to the pptp connection, this way it works and pptp users have access to both of the networks, but we really want to avoid it.

Maybe there's a feature or something that can be done on SBS 2011 to create this route automatically for the user ?

Question by:Marius Kaizerman
1 Comment
LVL 78

Accepted Solution

Rob Williams earned 2000 total points
ID: 38402382
Two possible options:

1)  You can use CMAK (connection Manager Administration Kit) to create a custom deployable client and add routes:

2) I wrote and have use the following script to add routes to client machines:

Assuming VPN client gets a IP
And the network to which you wish to route traffic is
Following will not work on Vista (see blow for Vista or newer)

Echo off
If Exist Result.txt del Result.txt
IPConfig >Result.txt
For /F "tokens=2 delims=:" %%A IN ('Find /I "10.10.10." Result.txt') Do Set NewIP=%%A
Rem ---------
Rem test output (to be removed)
Echo %NewIP%
Rem ----------
Rem Delete existing route if any
route delete
route add mask %NewIP%
Del Result.txt
Set NewIP=Nul

On Vista or any use:

Echo off
If Exist Result1.txt del Result1.txt
If Exist Result2.txt del Result2.txt
IPConfig >Result1.txt
Find /I "IPv4 Address. . . . . . . . . . . : 10.10.10." Result1.txt >Result2.txt
For /F "tokens=2 delims=:" %%A IN (Result2.txt) DO SET NewIP=%%A

Rem ---------
Rem test output (to be removed)
Echo %NewIP%
Rem ----------
Rem Delete existing route if any

rem route delete
rem route add mask %NewIP%
rem Del Result1.txt
rem Del Result2.txt
Set NewIP=Nul

Featured Post


Modern healthcare requires a modern cloud. View this brief video to understand how the Concerto Cloud for Healthcare can help your organization.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

How to fix a SonicWall Gateway Anti-Virus firewall blocking automatic updates to apps like Windows, Adobe, Symantec, etc.
LinkedIn blogging is great for networking, building up an audience, and expanding your influence as well. However, if you want to achieve these results, you need to work really hard to make your post worth liking and sharing. Here are 4 tips that ca…
Internet Business Fax to Email Made Easy - With  eFax Corporate (http://www.enterprise.efax.com), you'll receive a dedicated online fax number, which is used the same way as a typical analog fax number. You'll receive secure faxes in your email, f…
Monitoring a network: why having a policy is the best policy? Michael Kulchisky, MCSE, MCSA, MCP, VTSP, VSP, CCSP outlines the enormous benefits of having a policy-based approach when monitoring medium and large networks. Software utilized in this v…

873 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question