summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAdrian Kummerlaender2018-04-27 13:55:52 +0200
committerAdrian Kummerlaender2018-04-27 13:55:52 +0200
commitb42b3ecf0d5ea679126060c2e406aa8cbb774b77 (patch)
tree5f1b4024e7789407b8c42a78274ff3a3f1b72beb
parent249aee7d8983c69ec2cd8e62fae2a2e2440c0ec6 (diff)
downloadnixos_system-b42b3ecf0d5ea679126060c2e406aa8cbb774b77.tar
nixos_system-b42b3ecf0d5ea679126060c2e406aa8cbb774b77.tar.gz
nixos_system-b42b3ecf0d5ea679126060c2e406aa8cbb774b77.tar.bz2
nixos_system-b42b3ecf0d5ea679126060c2e406aa8cbb774b77.tar.lz
nixos_system-b42b3ecf0d5ea679126060c2e406aa8cbb774b77.tar.xz
nixos_system-b42b3ecf0d5ea679126060c2e406aa8cbb774b77.tar.zst
nixos_system-b42b3ecf0d5ea679126060c2e406aa8cbb774b77.zip
Add KIT VPN configuration
-rw-r--r--conf/vpn/T-TeleSec_GlobalRoot_Class_2.pem23
-rw-r--r--conf/vpn/kit.ovpn.nix19
-rw-r--r--configuration.nix7
3 files changed, 49 insertions, 0 deletions
diff --git a/conf/vpn/T-TeleSec_GlobalRoot_Class_2.pem b/conf/vpn/T-TeleSec_GlobalRoot_Class_2.pem
new file mode 100644
index 0000000..374b050
--- /dev/null
+++ b/conf/vpn/T-TeleSec_GlobalRoot_Class_2.pem
@@ -0,0 +1,23 @@
+-----BEGIN CERTIFICATE-----
+MIIDwzCCAqugAwIBAgIBATANBgkqhkiG9w0BAQsFADCBgjELMAkGA1UEBhMCREUx
+KzApBgNVBAoMIlQtU3lzdGVtcyBFbnRlcnByaXNlIFNlcnZpY2VzIEdtYkgxHzAd
+BgNVBAsMFlQtU3lzdGVtcyBUcnVzdCBDZW50ZXIxJTAjBgNVBAMMHFQtVGVsZVNl
+YyBHbG9iYWxSb290IENsYXNzIDIwHhcNMDgxMDAxMTA0MDE0WhcNMzMxMDAxMjM1
+OTU5WjCBg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ff --git a/conf/vpn/kit.ovpn.nix b/conf/vpn/kit.ovpn.nix
new file mode 100644
index 0000000..82a21ee
--- /dev/null
+++ b/conf/vpn/kit.ovpn.nix
@@ -0,0 +1,19 @@
+# adapted from https://www.scc.kit.edu/scc/net/openvpn/os/debian/kit.ovpn
+
+''
+client
+remote 141.52.8.20
+port 1194
+dev tun
+proto udp
+auth-user-pass
+nobind
+comp-lzo no
+tls-version-min 1.2
+ca ${./T-TeleSec_GlobalRoot_Class_2.pem}
+verify-x509-name "C=DE, ST=Baden-Wuerttemberg, L=Karlsruhe, O=Karlsruhe Institute of Technology, OU=Steinbuch Centre for Computing, CN=ovpn.scc.kit.edu" subject
+cipher AES-256-CBC
+auth SHA384
+verb 3
+script-security 2
+''
diff --git a/configuration.nix b/configuration.nix
index eba0215..8cb55a1 100644
--- a/configuration.nix
+++ b/configuration.nix
@@ -54,6 +54,13 @@
extraConfig = ''Storage=volatile'';
};
+ openvpn.servers = {
+ KIT = {
+ config = import ./conf/vpn/kit.ovpn.nix;
+ autoStart = false;
+ };
+ };
+
xserver = {
enable = true;
layout = "de";