Git Product home page Git Product logo

vpn-up-for-openconnect's Introduction

vpn-up-for-openconnect

VPN Up - Shell Script for OpenConnect for Mac OS | Command-Line Client for Cisco AnyConnect

Features

A shell script for OpenConnect which allows:

  • to define multiple VPN connections, using different protocols
  • to run openconnect without entering the username and password
  • to run in the background / quietly
  • to authenticate with a certificate
  • to authenticate using Two-Factor Authentication (2FA) from Duo
  • to check the status of the vpn connection

What's new

  • 🆒 added support for Two-Factor Authentication (2FA) from Duo
  • added support for using different protocols
  • added options (start, stop, status, restart, status)
  • can check status of the vpn connection

Sample configuration section

set options in file ~/.vpn/.env

VPN_NAME="VPN connection name"
VPN_HOST="vpn_server"
VPN_GROUP="vpn_group"
VPN_USER="vpn_login"
VPN_PASSWD=vpn_password
VPN_DUO2FAMETHOD=push #two factor method
SERVER_CERTIFICATE=""
PROTOCOL="anyconnect"
    # anyconnect       Compatible with Cisco AnyConnect SSL VPN, as well as ocserv (default)
    # nc               Compatible with Juniper Network Connect
    # gp               Compatible with Palo Alto Networks (PAN) GlobalProtect SSL VPN
    # pulse            Compatible with Pulse Connect Secure SSL VPN

BACKGROUND=TRUE
    # TRUE          Runs in background after startup
    # FALSE         Runs in foreground after startup
QUIET=TRUE
    # TRUE          Less output
    # FALSE         Detailed output
SUDO=FALSE
    # TRUE          
    # FALSE         
SUDO_PASSWORD=""

Run VPN Up

  1. Please make sure you have openconnect installed before moving on. Follow the instructions here.
  2. Copy the vpn-up.command file to the bin folder.
  3. Create .env file in ~/.vpn
  4. Make an alias alias vpn-up='~/bin/vpn-up.command start' in bash or zsh shell. Follow the instructions here.
  5. Run vpn-up to start and voilà.

vpn-up-for-openconnect's People

Contributors

architegrity avatar amindadgar avatar hardj avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.