Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(296)

Unified Diff: server/site_tests/network_VPN/000VPNGenesis

Issue 6609034: VPN: Test to set up & validate a Client connection to the Server (Closed) Base URL: ssh://git@gitrw.chromium.org:9222/autotest.git@master
Patch Set: Fix headers, even though the copyright year regex is wrong Created 9 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « server/site_linux_server.py ('k') | server/site_tests/network_VPN/001VPNNoKindSpecified » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: server/site_tests/network_VPN/000VPNGenesis
diff --git a/server/site_tests/network_VPN/000VPNGenesis b/server/site_tests/network_VPN/000VPNGenesis
new file mode 100644
index 0000000000000000000000000000000000000000..358b1ca9f74c77829053dee8cd237bdf7d7224a3
--- /dev/null
+++ b/server/site_tests/network_VPN/000VPNGenesis
@@ -0,0 +1,84 @@
+# Copyright (c) 2011 The Chromium OS Authors. All rights reserved.
+# Use of this source code is governed by a BSD-style license that can be
+# found in the LICENSE file.
+#
+# An example of how to set up a VPN from the Client (DUT), through the
+# Router to to the Server.
+#
+
+{ "name":"VPNGenesis",
+ "steps":[
+ ### Create WiFi connection from Client to Router.
+ [ "create", { "type":"hostap" } ],
+ [ "config", { "channel":"2412", "mode":"11b" } ],
+ [ "connect", { "security":"none" } ],
+
+ ### Create Client & Server VPN configurations.
+ ###
+ ### o Install certficiates files on Server, and Client.
+ ### o Create VPN configuration on the Server.
+
+ [ "install_files", { "system" : "server",
+ "files" :
+ { "/tmp/vpn-ca.crt":
+ site_eap_certs.ca_cert_1,
+ "/tmp/vpn-server.crt":
+ site_eap_certs.server_cert_1,
+ "/tmp/vpn-server.key":
+ site_eap_certs.server_private_key_1,
+ "/tmp/vpn-dh1024.pem":
+ site_eap_certs.dh1024_pem_key_1
+ }}],
+ [ "install_files", { "system" : "client",
+ "files" :
+ { "/tmp/ca.crt":
+ site_eap_certs.ca_cert_1,
+ "/tmp/client.crt":
+ site_eap_certs.client_cert_1,
+ "/tmp/client.key":
+ site_eap_certs.client_private_key_1
+ }}],
+ ### Configure and launch the VPN server.
+ ### Automatically kills any previously running server.
+ ###
+ ### There are two vpn_server_config() uses to ensure that the
+ ### internal configuration is persistent across invocations.
+ [ "vpn_server_config", { "kind" : "openvpn",
+ "config" :
+ { "port":"1194",
+ "proto":"udp",
+ "dev":"tun",
+ "ca":"/tmp/vpn-ca.crt",
+ "cert":"/tmp/vpn-server.crt",
+ "key":"/tmp/vpn-server.key",
+ "dh":"/tmp/vpn-dh1024.pem",
+ "server":"10.8.0.0 255.255.255.0",
+ "ifconfig-pool-persist":"/tmp/ipp.txt",
+ "keepalive":"10 120",
+ "persist-key":"",
+ "persist-tun":"",
+ "status":"/tmp/openvpn-status.log",
+ "verb":"0"
+ }
+ }],
+ [ "vpn_server_config", { "kind" : "openvpn",
+ "config" : { "comp-lzo":"" }
+ }],
+ ### Launch the VPN Client.
+ [ "vpn_client_load_tunnel" ],
+ [ "vpn_client_config", { "kind":"openvpn",
+ "files":{
+ "ca-certificate":"/tmp/ca.crt",
+ "client-certificate":"/tmp/client.crt",
+ "client-key":"/tmp/client.key" }
+ }],
+
+ ### Verify the client is connected to the server
+ [ "client_ping", { "ping_ip":"10.8.0.1",
+ "count":"10" } ],
+
+ [ "vpn_server_kill" ], # Shut down the VPN Server.
+ [ "vpn_client_kill" ], # Shut down the VPN Client.
+ [ "disconnect" ], # Disconnect WiFi setup
+ ],
+}
« no previous file with comments | « server/site_linux_server.py ('k') | server/site_tests/network_VPN/001VPNNoKindSpecified » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698