const.go 1.5 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546
  1. package ovpm
  2. // Version defines the version of ovpm.
  3. var Version = "development"
  4. const (
  5. // DefaultVPNPort is the default OpenVPN port to listen.
  6. DefaultVPNPort = "1197"
  7. // DefaultVPNProto is the default OpenVPN protocol to use.
  8. DefaultVPNProto = UDPProto
  9. // DefaultVPNNetwork is the default OpenVPN network to use.
  10. DefaultVPNNetwork = "10.9.0.0/24"
  11. // DefaultVPNDNS is the default DNS to push to clients.
  12. DefaultVPNDNS = "8.8.8.8"
  13. // DefaultDaemonPort is the port OVPMD will listen by default if something else is not specified.
  14. DefaultDaemonPort = 9090
  15. // DefaultKeepalivePeriod is the default ping period to check if the remote peer is alive.
  16. DefaultKeepalivePeriod = "2"
  17. // DefaultKeepaliveTimeout is the default ping timeout to assume that remote peer is down.
  18. DefaultKeepaliveTimeout = "4"
  19. etcBasePath = "/etc/ovpm/"
  20. varBasePath = "/var/db/ovpm/"
  21. _DefaultConfigPath = etcBasePath + "ovpm.ini"
  22. _DefaultDBPath = varBasePath + "db.sqlite3"
  23. _DefaultVPNConfPath = varBasePath + "server.conf"
  24. _DefaultVPNCCDPath = varBasePath + "ccd"
  25. _DefaultCertPath = varBasePath + "server.crt"
  26. _DefaultKeyPath = varBasePath + "server.key"
  27. _DefaultCACertPath = varBasePath + "ca.crt"
  28. _DefaultCAKeyPath = varBasePath + "ca.key"
  29. _DefaultDHParamsPath = varBasePath + "dh4096.pem"
  30. _DefaultCRLPath = varBasePath + "crl.pem"
  31. _DefaultStatusLogPath = varBasePath + "openvpn-status.log"
  32. )
  33. // Testing is used to determine whether we are testing or running normally.
  34. // Set it to true when testing.
  35. var Testing = false