-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathclientkeys.sh
More file actions
47 lines (42 loc) · 1.72 KB
/
Copy pathclientkeys.sh
File metadata and controls
47 lines (42 loc) · 1.72 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
#!/bin/bash
cd /etc/openvpn/easy-rsa
./easyrsa build-client-full client1 nopass
./easyrsa build-client-full client2 nopass
./easyrsa build-client-full client3 nopass
./easyrsa build-client-full client4 nopass
./easyrsa build-client-full client5 nopass
./easyrsa build-client-full client6 nopass
mkdir /etc/openvpn/clientkeys
cd /etc/openvpn/clientkeys
mkdir client1
mkdir client2
mkdir client3
mkdir client4
mkdir client5
mkdir client6
cd /etc/openvpn
cp ./easy-rsa/pki/ca.crt
cp ./serverkeys/ta.key ./clientkeys/client1
cp ./serverkeys/ta.key ./clientkeys/client2
cp ./serverkeys/ta.key ./clientkeys/client3
cp ./serverkeys/ta.key ./clientkeys/client4
cp ./serverkeys/ta.key ./clientkeys/client5
cp ./serverkeys/ta.key ./clientkeys/client6
cp ./serverkeys/ca.crt ./clientkeys/client1
cp ./serverkeys/ca.crt ./clientkeys/client2
cp ./serverkeys/ca.crt ./clientkeys/client3
cp ./serverkeys/ca.crt ./clientkeys/client4
cp ./serverkeys/ca.crt ./clientkeys/client5
cp ./serverkeys/ca.crt ./clientkeys/client6
cp ./easy-rsa/pki/issued/client1.crt ./clientkeys/client1
cp ./easy-rsa/pki/issued/client2.crt ./clientkeys/client2
cp ./easy-rsa/pki/issued/client3.crt ./clientkeys/client3
cp ./easy-rsa/pki/issued/client4.crt ./clientkeys/client4
cp ./easy-rsa/pki/issued/client5.crt ./clientkeys/client5
cp ./easy-rsa/pki/issued/client6.crt ./clientkeys/client6
cp ./easy-rsa/pki/private/client1.key ./clientkeys/client1
cp ./easy-rsa/pki/private/client2.key ./clientkeys/client2
cp ./easy-rsa/pki/private/client3.key ./clientkeys/client3
cp ./easy-rsa/pki/private/client4.key ./clientkeys/client4
cp ./easy-rsa/pki/private/client5.key ./clientkeys/client5
cp ./easy-rsa/pki/private/client6.key ./clientkeys/client6