cisco-vpn

1.0.2 • Public • Published

cisco-vpn

Wrapper around the Cisco AnyConnect VPN client.

Installation

npm install cisco-vpn

Quickstart

const vpn = require('cisco-vpn')({
    server: 'vpn.example.org',
    username: 'uncreative-username',
    password: 'super-secret-password'
})
 
vpn.connect()
    .then(() => console.log('connected!'))
 
// some time later
vpn.disconnect()
    .then(() => console.log('disconnected!'))

API

require('cisco-vpn')(options)

  • options <Object>:
    • exe <String>: default: C:/Program Files (x86)/Cisco/Cisco AnyConnect Secure Mobility Client/vpncli.exe
    • server <String>: required
    • username <String>: required
    • password <String>: required
  • returns the vpn <Object>

vpn.connect()

  • returns a <Promise> which:
    • resolves if the vpn was connected
    • rejects if an error occured

vpn.disconnect()

  • returns a <Promise> which:
    • resolves if the vpn was disconnected
    • rejects if an error occured

License

WTFPL – Do What the F*ck You Want to Public License.

Made with ❤️ by @MarkTiedemann.

Package Sidebar

Install

npm i cisco-vpn

Weekly Downloads

13

Version

1.0.2

License

WTFPL

Unpacked Size

3.72 kB

Total Files

4

Last publish

Collaborators

  • marktiedemann