About the App
The installation and setup of sstpc is all done on command line. You will need to start a terminal session and run sstpc with the appropriate command line options to successfully connect. Script to start sstp-client on a Mac, connecting to Microsoft VPN, with ability to use Apple's KeyChain GitHub Instantly share code, notes, and snippets.
- App name: sstp-client
- App description: SSTP (Microsofts Remote Access Solution for PPP over SSL) client
- App website: http://sstp-client.sourceforge.net
Install the App
- Press
Command+Space
and type Terminal and press enter/return key. - Run in Terminal app:
ruby -e '$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)' < /dev/null 2> /dev/null
and press enter/return key.
If the screen prompts you to enter a password, please enter your Mac's user password to continue. When you type the password, it won't be displayed on screen, but the system would accept it. So just type your password and press ENTER/RETURN key. Then wait for the command to finish. - Run:
brew install sstp-client
Done! You can now use sstp-client
.
Similar Software for Mac
#!/bin/bash |
SERVICE_NAME='my-example-vpn' |
SERVICE_URL='my-example-vpn.com' |
if [[ ${#USER}> 1 ]] |
then |
read -p 'Log in as ${USER}? [y/n] ' LIA |
else |
LIA = 'n' |
fi |
if [[ $LIA'y' ]] || [[ $LIA'Y' ]] |
then |
UN=$USER |
else |
read -p 'VPN Username: ' UN |
fi |
PW_KC=$(security find-generic-password -a $UN -s $SERVICE_NAME -w 2> /dev/null) |
PW='' |
if [[ ${#PW_KC}> 1 ]] |
then |
read -p 'Use password from keychain? [y/n] ' UPWKC |
if [[ $UPWKC'y' ]] || [[ $UPWKC'Y' ]] |
then |
PW=$PW_KC |
fi |
fi |
if [[ ${#PW} 0 ]] |
then |
read -sp 'VPN Password: ' PW |
echo |
read -p 'Store password in keychain? [y/n] ' UPWKC |
if [[ $UPWKC'y' ]] || [[ $UPWKC'Y' ]] |
then |
security add-generic-password -a $UN -s $SERVICE_NAME -w $PW |
fi |
fi |
echo -e 'nConnecting after sudo..' |
sudo sstpc --log-stderr --log-level 1 --cert-warn --user $UN --password $PW$SERVICE_URL usepeerdns require-mschap-v2 noauth noipdefault defaultroute refuse-eap noccp |
commented Jan 11, 2017
The sstp-client package can be installed with homebrew ( |
commented Oct 22, 2019
Hello @bigonese, how can I check connection status? Thank you so much for this script. |
commented Oct 30, 2019
@ndedonald, if you use |