Code Monkey home page Code Monkey logo

openvpn-config-generator's Introduction

OpenVPN-Config-Generator

OpenVPN-Config-Generator is made to help automate the process of creating OpenVPN configurations.

You can use one of the pre-built templates if your new to OpenVPN or you can build your own template to fit your needs.

Install

OpenSSL is required to generate certificates and OpenVPN is needed to create tlsauth keys. Make sure OpenVPN and OpenSSL are installed.

Run pip install -r requirements.txt to install needed python packages.

Template File

Template files are written in JSON and have 4 keys in them. They are meta, client, server, and both.

###client, server, both### These 3 keys follow the same syntax rules. Keys in the client section will be put in the client's configuration files, keys in the server section will be put in the server's configuration file, and keys in both section will be put in both the client's and server's configuration files.

The keys value defines how the config file should be written

  • String: The config file will be written with "key value"
  • Boolean: When the value is set to true the key will be written alone to the config file.
  • Array: The key will be written as "key value" for each value

Example:

{
  "server": "10.8.8.0 255.255.255.0",
  "push": ["\"redirect-gateway def1 bypass-dhcp\"", "\"dhcp-option DNS 8.8.8.8\""],
  "duplicate-cn": true
}

Output:

server 10.8.8.0 255.255.255.0
push "redirect-gateway def1 bypass-dhcp"
push "dhcp-option DNS 8.8.8.8"
duplicate-cn

###meta### The meta section is used for information related to the build. The following keys are accepted:

  • savecerts: If set to true this will save all the certs and keys used to generate the configurations.
  • embedkeys: If set to true the keys and certs needed to run the configuration will be embed into the ovpn file. If false they will be referenced by filename.
  • tls-auth: If set to true tls-auth will be configured for clients and servers.
  • keysize: The size of the keys to be generated.
  • dhsize: The size of the Diffie–Hellman parameters that will be generated.

openvpn-config-generator's People

Contributors

drewsif avatar

Watchers

James Cloos 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.